I encountered an Oracle function that is new to me. It is used in a where clause/join definition:
FROM T_NIS A, T_MEMBERS B
WHERE A.F_POSTCODE(+) = REPLACE(B.F_POSCOD, ' ')
This REPLACE -- what does it do? Is it similar to NVL?

    Requires Free Membership to View

REPLACE function replaces the occurrence of a sub-string in a string with a specified second sub-string. In the event the second sub-string is not specified, then it removes the occurrence of the first sub-string.

In your example all white spaces will be removed from the valid in B.F_POSCOD column before the equality is verified.

This was first published in June 2004

There are Comments. Add yours.

 
TIP: Want to include a code block in your comment? Use <pre> or <code> tags around the desired text. Ex: <code>insert code</code>

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy
Sort by: OldestNewest

Forgot Password?

No problem! Submit your e-mail address below. We'll send you an email containing your password.

Your password has been sent to: