Unable to understand Datastage Director Warning

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
udayk_2007
Participant
Posts: 72
Joined: Wed Dec 12, 2007 2:29 am

Unable to understand Datastage Director Warning

Post by udayk_2007 »

Hi

I am getting following warning in Director Log

FileName: When checking operator: When validating export schema:
At field "Column_ABCD": "null_field" length (0) must match field's fixed width (40)

Can anybody please suggest how can i get rid of this warning

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

Post by ray.wurlod »

A Search would have garnered your answer faster. Your data type is Char(40), therefore ANY value, whether or not that value represents NULL, must contain forty characters. The Null Field Value property contains a value that will be interpreted as NULL on reading or be written if NULL is received into the writing stage when writing. Since the column is of data type Char(40) (string[40]) the Null Field Value must contain 40 characters.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
udayk_2007
Participant
Posts: 72
Joined: Wed Dec 12, 2007 2:29 am

Post by udayk_2007 »

Hi

Thanks for your response

Actually i was getting that warning for reject files

now i have put 40 spaces in the null field value of those columns and the warning got resolved.
naveen19
Participant
Posts: 52
Joined: Tue Mar 06, 2007 9:08 am
Location: India
Contact:

Post by naveen19 »

Hi,

Try to use below below logic.. putting 40 spaces is not good for the design

If IsNull(column_name) Then '0' Else If Len(TrimB(column_name)) =0 Then '0' Else column_name

Regards...Naveen.K
udayk_2007
Participant
Posts: 72
Joined: Wed Dec 12, 2007 2:29 am

Post by udayk_2007 »

you are correct..putting 40 spaces is not the perfect solution ,its just a workaround to reduce warnings

your logic can be implemented in this case but it will require a transformer to put that code,which will hamper the job performance

Anyways...Thanks for your help
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

I'm curious how that is "not good for the design". Or how putting a zero in a CHAR(40) is an appropriate represention of an empty string field. :?

In my opinion, what you did is not a workaround but rather the solution. The fact that the warning is now gone should be a big clue, a 'workaround' would involve something like using a message handler to to demote it. Regardless, please mark the thread with the outcome of your choice using the buttons at the top of the screen.

Thanks.
-craig

"You can never have too many knives" -- Logan Nine Fingers
Post Reply