Page 1 of 1

Issue with Null Indicator/ db2

PostPosted: Mon Mar 21, 2011 7:43 pm
by rlimkar
Hi Friends,
The null indicator for the decimal columns of the table is not getting set though those column contains the value as NULL.
I had fired an sql in SPUFI by adding where clause as column name is null and it shows the result.
But in the program when I displyaed the value for the field and it is coming as 000 (zeroes). :o and thats why null indicator is not getting set but not able to understand from where it is getting zeros??

Not able to identify what is the issue?
Looking forward to get some replies...

Thanks in anticipation.

Note : Verfied the sql, data type, nullable column and which is fine. Just to let u all know I am using it in multirow fetch cursor.

Re: Issue with Null Indicator/ db2

PostPosted: Mon Mar 21, 2011 9:23 pm
by stoked
rlimkar wrote:Hi Friends,
I had fired an sql in SPUFI by adding where clause as column name is null and it shows the result.

"column name is null"? I wouldn't have thought that is possible.

Re: Issue with Null Indicator/ db2

PostPosted: Tue Mar 22, 2011 12:55 am
by prino
rlimkar wrote:Hi Friends,

I prefer to select my own friends!

rlimkar wrote:... I had fired an sql in SPUFI by adding where clause as column name is null and it shows the result. ...

You should not fire sql's in SPUFI, as that will severely damage the SQL.

Re: Issue with Null Indicator/ db2

PostPosted: Tue Mar 22, 2011 10:56 am
by NicC
Perhaps your column has a default value?

Re: Issue with Null Indicator/ db2

PostPosted: Tue Mar 22, 2011 7:22 pm
by rlimkar
The DB2 version is changed from version 8 to 9 , is this a reason ??

Re: Issue with Null Indicator/ db2

PostPosted: Tue Mar 22, 2011 7:29 pm
by NicC
1) did it work in version 8?
2) look at the doumentation for version 9 to see what the changes are. Do any of them look as though they could cause this?

Re: Issue with Null Indicator/ db2

PostPosted: Tue Mar 22, 2011 7:37 pm
by rlimkar
Yes.. it was working fine in Db2 v8 .
Bcoz that was the only change happened in system after program delivered in production. And its not working i prod now..
If you have the link for the guide for Db2 v9 , could you please share..

Re: Issue with Null Indicator/ db2

PostPosted: Wed Mar 23, 2011 2:08 am
by NicC
Clue 1: DB2 is IBM.
Clue 2: IBM has its manuals available online.
Clue 3: The forum has loads of topics mentionong how to get to the manuals
If all else fails...
Clue 4: Google