how to convert nullable to not null values

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
developeretl
Participant
Posts: 89
Joined: Sat Jul 24, 2010 11:33 pm

how to convert nullable to not null values

Post by developeretl »

Hi,
Iam having trouble converting the null values to not null. Can you please guide how to convert the nullable values to not null using the transformer stage or any db2 query ( i used nvl and coalescequery it is not working )
Iam getting the values from the database which are having null values and i need to do transformation and updated them into another table there those fields are not null.
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

Please be more specific about what you mean by "it is not working" and what - precisely - you want to do with inbound NULL values.

It should be straightforward once you have decided on how NULL is to be represented in the not null column - simply convert any inbound ("out of band") null into that representation ("in band null"). Use NullToValue() function in a Transformer stage.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
sultan@cts
Participant
Posts: 31
Joined: Thu Jul 05, 2007 11:57 pm
Location: India
Contact:

Re: how to convert nullable to not null values

Post by sultan@cts »

developeretl wrote:Hi,
Iam having trouble converting the null values to not null. Can you please guide how to convert the nullable values to not null using the transformer stage or any db2 query ( i used nvl and coalescequery it is not working )
Iam getting the values from the database which are having null values and i need to do transformation and updated them into another table there those fields are not null.
We are having NullToValue function in transformer stage.Make use of this.
Thanks
Sultan
Sainath.Srinivasan
Participant
Posts: 3337
Joined: Mon Jan 17, 2005 4:49 am
Location: United Kingdom

Post by Sainath.Srinivasan »

Why is the response from sultan@cts rated as level 1 ? That is your solution (assuming you only are looking for transforming Null into a non-null value).

Search for NullToEmpty or NullToValue.
ETLJOB
Participant
Posts: 87
Joined: Thu May 01, 2008 1:15 pm
Location: INDIA

Post by ETLJOB »

It looks like any body can give rating for the solutions. I just checked it on your reply :wink:
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

I guess it's because it didn't add anything new. NullToValue() was already mentioned in my answer.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
Post Reply