Output column 12/13/2012,20180205 coming like this

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
vsvvreddy
Premium Member
Premium Member
Posts: 2
Joined: Wed Jul 19, 2017 8:55 am

Output column 12/13/2012,20180205 coming like this

Post by vsvvreddy »

Please help em to fix the output value. We are expecting to see the only one value. wrong data is coming in source file . please help me to clena up the data nd fix the output value
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

Trying to follow along here.

If you have a csv (comma separated values) file and one of the fields has a comma inside of it as data, you'll need to make sure that field is enclosed in quotes. If your file looks like this, then (ignoring the "xxx" bits) it will be read as two fields:

Code: Select all

xxx,xxx,12/13/2012,20180205,xxx
If it looks like this, then it's just one field:

Code: Select all

xxx,xxx,"12/13/2012,20180205",xxx
So, is that what is going on? There are no quotes so it is parsed as two separate fields?
-craig

"You can never have too many knives" -- Logan Nine Fingers
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

And, if they ARE being parsed as two separate fields, then it should be a simple Transformer stage expression to concatenate them with a comma in between.
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