tFileOutputDelimited with 2 line custom header

tFileOutputDelimited with 2 line custom header

Hi
when populating a delimited file from a DB , i can choose that it include HEADER...
how do i create said output with my own 2 line header , with my relevant details .
and then bring in my data
Regards
============================================================================
example:
FILTYPE00001-as7vlkdf9923j-kljsda89823m-20110637051002 //HEADER line 1 - file information i.e. file type , guid , date
#data1~data~data3 //HEADER line 2 - same as header but starts with #
data1~data2~data3 //row1 from data DB
data1~data2~data3 //row2 from data DB
data1~data2~data3 //row3 from data DB

============================================================================
One Star

Re: tFileOutputDelimited with 2 line custom header

Hi
A workaround is to load these 2 line header first into one output delimited file and then load other rows by selecting "append" option on tFileOutputDelimited.
Regards,
Pedro

Re: tFileOutputDelimited with 2 line custom header

Hi Pedro
sorry still new to talend
I understand the concept what component do i use to populate the file withe the header
as the first line of the header has a string describing filetype , then i insert a GUID and getDate() for the date
(i used String newGUID = java.util.UUID.randomUUID().toString() to generate and assigned it as global, using globalMap.put("GUID",newGUID)
the second line being the schema data header bu prefixed with #.
could you elaborate :
i am trying the following , see screen shots

and pass that to my first output file ... but no luck
One Star

Re: tFileOutputDelimited with 2 line custom header

Hi
The error is because tJavaFlex cannot link tFileInputDelimited.
You might create a job as the following image.
There is no need to use tJavaFlex here.
Regards,
Pedro