source file layout

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
vij
Participant
Posts: 131
Joined: Fri Nov 17, 2006 12:43 am

source file layout

Post by vij »

Hi all,

I have a doubt regarding the source file layout.
I have 2 source files F1 and F2.The total length of all the columns in F1 and F2 are the same, but the no.of columns are different.

Suppose F1 has this layout :

columnname length
col1 200
col2 50

----------

columnname length
colmn1 100
colmn2 50
col3 50
col4 50

in the above example, even if the total column lengths are the same(250), the format/layout differs.
here comes my question : is it possible to use the same file structure for both F1 and F2?

Pls help me solving this,

thanks
loveojha2
Participant
Posts: 362
Joined: Thu May 26, 2005 12:59 am

Post by loveojha2 »

Are there any separators in between the columns or it is a fixed length file.

You can read the entire row in the file as a column and after that you can process individual columns separately. With such a case you can still have same structure for both of the files.
Success consists of getting up just one more time than you fall.
vij
Participant
Posts: 131
Joined: Fri Nov 17, 2006 12:43 am

Post by vij »

loveojha2 wrote:Are there any separators in between the columns or it is a fixed length file.

You can read the entire row in the file as a column and after that you can process individual columns separately. With such a case you can still have same structure for both of the files.
Hi loveojha2,
ur reply was useful and there are no seperators, I think its not a problem anyways! I will read the whole file as a column and then split it accordingly!

Thanks a lot!
Post Reply