First line is column names in Input Tab

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
sumitgulati
Participant
Posts: 197
Joined: Mon Feb 17, 2003 11:20 pm
Location: India

First line is column names in Input Tab

Post by sumitgulati »

Hi,

I have a job that reads an Oracle table and inserts it into a sequential file. I see an option in Sequential file stage in Input\Format tab - 'First line is column names'. I read the help on this and it says:

"Select this check box if the first row of data in the file contains column names. This option is cleared by default, i.e., the first row in the file contains data."

I did not quite understand it.

1) Does it mean that the first record from the input data will be ignored and the data will be processed into the sequential file from the second record.
OR
2) Does it mean that the sequential file stage will insert the column names defined in the Input\Columns tab into the file as a first line.

Kindly clarify.

Thanks and Regards,
-Sumit
adamski
Charter Member
Charter Member
Posts: 54
Joined: Thu Mar 20, 2003 5:02 pm

Post by adamski »

The second assumption is correct.
sumitgulati
Participant
Posts: 197
Joined: Mon Feb 17, 2003 11:20 pm
Location: India

Post by sumitgulati »

Thanks a lot. One more clarification. "First line is column names" in the Output\Format tab means that while reading the sequential file it will ignore the first record and start the data processing from the second record. Am I correct?

Thanks and Regards,
-Sumit
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

Actually, in a way, both are correct...

1) True when reading a sequential file with the option checked... even if the first record isn't column headings! :wink:

2) True when writing to a sequential file with the option checked and the file either doesn't exist or is being overwritten. If you are appending to the end of an existing file, no column headings are added.
-craig

"You can never have too many knives" -- Logan Nine Fingers
sumitgulati
Participant
Posts: 197
Joined: Mon Feb 17, 2003 11:20 pm
Location: India

Post by sumitgulati »

Thanks Craig.

-Sumit
Post Reply