^m (new line character) between statments

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
sri75
Premium Member
Premium Member
Posts: 132
Joined: Thu Sep 09, 2004 12:42 pm

^m (new line character) between statments

Post by sri75 »

Hi HI,

I am getting data from sybase table like this. whole line as one record

STATMENT. ^M ^M NEXT STATMENT. ^M^M THANK YOU

there are new line characters between these statments.before I load the data into oracle table, I need to split this one record to 3 records , each on separte line. can you please let me know how to acheive this


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

Post by ray.wurlod »

Get version 8.5 and use a looping construct within a Transformer stage. Easy!

Until you do that, the easiest way is simply to write to a text file (the Char(13) characters become line terminators. Then (in a separate job, if you're using a parallel job) read back from that file.

Otherwise you can parse into separate columns and use a Pivot 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.
sri75
Premium Member
Premium Member
Posts: 132
Joined: Thu Sep 09, 2004 12:42 pm

Post by sri75 »

Thanks Ray for your suggestion. I will start working on taht

Thanks
Post Reply