Page 1 of 1

Header in the output file

Posted: Mon Apr 21, 2008 12:12 pm
by saini
Hi,

How can we add header to the output file?
I need to generate a file which has column name along with the records.
How can I get the column names in the job.

Thanks!!!
saini

Posted: Mon Apr 21, 2008 12:23 pm
by kcbland
If you don't like the column names used in the job design then don't use the option to include column names as the first line in the sequential file. Consider creating a blank text file with just your custom column names as the only line of data. Then, from your job just Append to existing file when writing out the rows.

Posted: Mon Apr 21, 2008 12:57 pm
by kumar_s
Is that two different question or the same question?
If you want to add Header, based on content, you can choose, the first name as columsn name option or use After job subroutine or ExecuteCommand Stage.
If Filename should be the header, then prefer the later options, by passing the Filename as parameter.
If you like to pass the filename for all the records, include, "FileNameColumn" option from the Input sequential file stage.