Sort stage writes #'s in place of null in output to seq file

Post questions here relative to DataStage Server Edition for such areas as Server job design, DS Basic, Routines, Job Sequences, etc.

Moderators: chulett, rschirm, roy

Post Reply
jmryan2000
Participant
Posts: 5
Joined: Mon May 01, 2006 7:23 am

Sort stage writes #'s in place of null in output to seq file

Post by jmryan2000 »

I need to sort a fixed length sequential file by 2 columns and tried using the sort stage. When reviewing the output through the data viewer in DS, the data appears OK. When reviewing the output in a text editor (TextPad), any fields that contained no data were replaced with #'s (though fields that have trailing spaces retain the spaces). So a 5 char field with no data comes across as #####. The data coming into the sort stage doesn't have the #'s. Any ideas why this is occurring and how to stop it?

Thanks!
kris007
Charter Member
Charter Member
Posts: 1102
Joined: Tue Jan 24, 2006 5:38 pm
Location: Riverside, RI

Post by kris007 »

If you go to the Inputs tab on the (target)sequential file and then go to the Format tab what do you see in the Default padding field. Change it to what you want it to be. :wink:
Kris

Where's the "Any" key?-Homer Simpson
jmryan2000
Participant
Posts: 5
Joined: Mon May 01, 2006 7:23 am

Post by jmryan2000 »

That did the trick. Thanks, again!
ray.wurlod
Participant
Posts: 54595
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

Diagnostician Note
Don't be in too much of a hurry to attribute blame to a particular stage type.


Here the subject line suggests a problem with the Sort stage, which may mislead future searchers. The problem wasn't. DataStage did exactly what it was programmed to do - via the pad character property in the Sequential File 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.
Post Reply