Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi, I would like to create a job which consumes the xml which is a directory and loads them into a mysql database, but I wonder if with TOS we can be able to browse a directory and retrieve the data from the XML found in the directory and load them into the database? If it is possible to browse a directory with component, do we do it?
Hi
You can use tFileList component to iterates a set of files or folders in a given directory based on a filemask pattern, here is a scenario.
https://help.talend.com/r/en-US/8.0/tfilelist/tfilelist-tfileinputdelimited-tlogrow-tlogrow-iterating-on-file-directory-standard-component-the
Regards
Shong
Hi
You can use tFileList component to iterates a set of files or folders in a given directory based on a filemask pattern, here is a scenario.
https://help.talend.com/r/en-US/8.0/tfilelist/tfilelist-tfileinputdelimited-tlogrow-tlogrow-iterating-on-file-directory-standard-component-the
Regards
Shong
Sorry, I don't understand your problem here, tfileinputXml disappears?
A simple job design looks like:
tFileList--iterate--tFileInputXML--main--tDBOutput
@Not defined Not defined If you are using a tFlieList to iterate multiple files one by one, there is a global variable that stores the current file path,
((String)globalMap.get("tFileList_1_CURRENT_FILEPATH"))
So, use this global variable in the File name/Stream field on tFileInputXML.