|
|
Re: using NULLIF statement for two conditions. [message #161616 is a reply to message #161612] |
Mon, 06 March 2006 06:01   |
miltony
Messages: 5 Registered: March 2006
|
Junior Member |
|
|
Eg:-
dte_exp position(294:301) date "YYYYMMDD" NULLIF dte_exp = BLANKS,
from a data file, the values from 294 to 301 columns to be moved to a column dte_exp of a table.
The above NULLIF statement assigns null, if the columns from 294 to 301 is blanks.
But my data file have "all zeroes" also. So I want to check for both "all zeroes" and blanks and assign both of them as NULL.
Please anyone give a solution.
|
|
|
|
Re: using NULLIF statement for two conditions. [message #529505 is a reply to message #166979] |
Tue, 01 November 2011 10:13   |
 |
illectronic
Messages: 1 Registered: November 2011 Location: NYC
|
Junior Member |
|
|
I also would like to know how to specify two "nullif" conditions. For example I have columns that have "?" or " " that signifies NULL data.
The post above gave me an error.
SQL*Loader-350: Syntax error at line 12.
Expecting positive integer or column name, found keyword nullif.
MONEY_IN_ACTIVE nullif(nullif(MONEY_IN_ACTIVE,' '),'? '),
Thanks
[Updated on: Tue, 01 November 2011 10:14] Report message to a moderator
|
|
|
|
Re: using NULLIF statement for two conditions. [message #529539 is a reply to message #529508] |
Tue, 01 November 2011 13:06  |
joy_division
Messages: 4963 Registered: February 2005 Location: East Coast USA
|
Senior Member |
|
|
syakobson wrote on Tue, 01 November 2011 11:43MONEY_IN_ACTIVE nullif(nullif(:MONEY_IN_ACTIVE,' '),'?')
SY.
If this is being used in SQL*Loader, which it looks like it is, then it would be:
MONEY_IN_ACTIVE "nullif(nullif(:MONEY_IN_ACTIVE,' '),'?')"
|
|
|