Default to Zero after lookup for Null feilds

Post questions here relative to DataStage Enterprise/PX Edition for such areas as Parallel job design, Parallel datasets, BuildOps, Wrappers, etc.

Moderators: chulett, rschirm, roy

Post Reply
sainath
Premium Member
Premium Member
Posts: 138
Joined: Fri Nov 19, 2004 3:57 pm

Default to Zero after lookup for Null feilds

Post by sainath »

Hi

I am just doing a normal lookup from data set file..

I noticed that data stage is inserting Zero value for null fields after lookup. I saw the value in peek stage and datatype is Integer ,,,


I just want to confirm is this is true,,,

please confim


thks
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

True? We can only choose to believe what you told us.

Check your job log for warnings, and check null field value in the target stage. Check, too, that the output column is marked as nullable.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
suse_dk
Participant
Posts: 93
Joined: Thu Aug 11, 2011 6:18 am
Location: Denmark

Post by suse_dk »

If you want a null value from your lookup operation the field needs to be nullable on both the input and output side - otherwise it will default to 0 for a integer
_________________
- Susanne
Post Reply