Missing delimiter

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
kkumardatastage
Participant
Posts: 84
Joined: Sat Jul 19, 2008 8:50 am

Missing delimiter

Post by kkumardatastage »

Hi

please could any one help me in this following issue.

Input file with || format
a||b||c||d||e
1||2||3||4||5
g||g||e||6

in 3rd row after 6 there is missing || Following is small job

Sequential File Stage---->Transformer------>Sequential File
|
|
|
Reject

In Reject file i am able to see the 3rd row of the file i.e the record with missing || in single Column, but the requirement say record should go further for business process. please could u help how can i get that record process. This is a parallel job.

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

Post by ray.wurlod »

Read the file using a single VarChar field and parse it in a downstream Transformer stage, wherein you can handle the missing column appropriately (supply a default value?).
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
kkumardatastage
Participant
Posts: 84
Joined: Sat Jul 19, 2008 8:50 am

Post by kkumardatastage »

Thanks Ray

But we dont want to read the file in single VarChar field, is its possible to do it in different way.

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

Post by kris007 »

That's an odd requirement. How you read the file should not matter as long as you are processing all the records required. Ray's suggestion to read the file in a single field and using a Transformer Stage should work fine.
Kris

Where's the "Any" key?-Homer Simpson
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

Pick up the rejects in the Sequential File stage with a reject link, reparse it (Column Import stage perhaps), generate the default value for the missing field (Column Generator stage perhaps) and funnel the two sets of rows back together.
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