Page 1 of 1

Issue with null values

Posted: Wed May 09, 2007 11:12 am
by rajkraj
I am comparing seq file data with table data. 3 keys combination is used as primary key.

But some of my record's key column values are null. Pls suggest me, how to compare null values?

Posted: Wed May 09, 2007 11:21 am
by DSguru2B
Preprocess the inputs and replace NULL values to a default value for comparison.

Re: Issue with null values

Posted: Wed May 09, 2007 12:54 pm
by muruganr117
rajkraj wrote:I am comparing seq file data with table data. 3 keys combination is used as primary key.

But some of my record's key column values are null. Pls suggest me, how to compare null values?

Hi,

You can preprocess it using NVL functions which will replace null with the prescribed text.

regards
Murugan

Posted: Wed May 09, 2007 3:14 pm
by pradeepleon
Replace the NULL values to a default value then do the comparison.

Posted: Wed May 09, 2007 4:54 pm
by ray.wurlod
First, a sequential file has no data types, it contains only text. So it can only contain a "representation" of NULL, not a true NULL.

Second, a key - by definition - can not be null.

Therefore, you may need to re-think your design. If these columns have documented null representations, then the Sequential File stage(s) that read them will convert those representations to true NULLs, in which case the only safe way to test for them is to use the IsNull() function.