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

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

[resolved] Seeding tFileList a list of files from database

I am trying to seed tFileList a list of files that I pulled from a table using Talend java. How can I dynamically set this up? It looks like I have to manually add in the file names to tFileList. Can I feed in a csv file?
In example:
Grab file names from a database >> store it in a csv file >> feed it to tFileList
Labels (4)
1 Solution

Accepted Solutions
Anonymous
Not applicable
Author

Hi
If you pull the file name (or file path) from database, not the file itself, you can iterate each file name directly without tFileList component. For example:
tMysqlInput--row1--tFlowToIterate---iterate-->the rest of job.
On the rest of job, you can access the current file name (or file path), use this expression:
(String)globalMap.get("row1.filename")
//filename is the column name;
Best regards
Shong

View solution in original post

5 Replies
Anonymous
Not applicable
Author

Hi
Just store the csv file into an empty directory. Then use tFileList to locate this directory and set Filemask "*".
Regards,
Pedro
Anonymous
Not applicable
Author

This doesnt actually process the raw data files. It only processes the csv file which holds the name of each file to be processed.
I am trying to feed tFileList a csv which contains targeted set of files for processing.
_AnonymousUser
Specialist III
Specialist III

give this a try:
tFileInput--row-->flowToIterate-->tFileInput---row--->(rest of job)
the first file input should contain your filenames. you retrieve them from the iterate with a call to the globalMap.
Anonymous
Not applicable
Author

Yeah this is a lot better solution.
Anonymous
Not applicable
Author

Hi
If you pull the file name (or file path) from database, not the file itself, you can iterate each file name directly without tFileList component. For example:
tMysqlInput--row1--tFlowToIterate---iterate-->the rest of job.
On the rest of job, you can access the current file name (or file path), use this expression:
(String)globalMap.get("row1.filename")
//filename is the column name;
Best regards
Shong