Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Join us in Bucharest on Sept 18th for Qlik's AI Reality Tour! Register Now
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

create output file with rolling file name

Hi ,
I need to create a job which will create a new output file(rolling file name) for every time I run the job. some thing like
out_001.xml
out_002.xml
out_003.xml
do you have any idea to achieve this using Talend?
Thanks in advance.
Labels (3)
8 Replies
Anonymous
Not applicable
Author

keep a count on a DB/file for this job
so everytime, job starts you read this value and set it in a variable (used in the output file)
good?
alevy
Specialist
Specialist

Or you can use tFileList --> IterateToFlow --> tMap (to parse file numbers) --> tAggregateRow (to find the max) --> tSetGlobalVar and then use the global variable in your file name.
_AnonymousUser
Specialist III
Specialist III

Or you can use tFileList --> IterateToFlow --> tMap (to parse file numbers) --> tAggregateRow (to find the max) --> tSetGlobalVar and then use the global variable in your file name.

can you discuss the process in more details , like select bla bla from bla bla then connect to bla bla ..
thx
alevy
Specialist
Specialist

See screenprint
Anonymous
Not applicable
Author

thanks alevy.. I tried another way..
Anonymous
Not applicable
Author

thx alevy
@ashu : will you please discuss your way here too ..
Anonymous
Not applicable
Author

I have one approach where I appended date and time in outputfile like dd-mm-yyyy_hh_MM_ss
Anonymous
Not applicable
Author

it was so simple.. I just created a table with one row.. two columns.. FileName and Sequence... i will be querying that table to get the filename and sequence number.. after that increment the sequence number..
here I'm attaching my job but its different from what I explained.. in tjavarow I'm doin some condition checks...