I have a tFileList which iterates through a directory of excel files and a tMap to append the CurrentPath, Directory to the flow.
For each file I read the contents but I want to include the modified date as well so I have the tFileProperties as lookup into a 2nd tmap and I use ((String)globalMap.get("tFileList_1_CURRENT_FILEPATH")) in the tFileInputExcel and tFileProperties
I tried matching the CurrentPath [set in tMap1 using ((String)globalMap.get("tFileList_1_CURRENT_FILEPATH")) ] to the tFileProperties basepath and abspath but my output doesn't match for any,
I also changed the tMap lookupModel to reload at each row.
I guess in a nutshell how do I match the tFileProperties to the flow of data out of the same File?
Tag as "solved" for others! Kudos to thanks!
I did use reload for each row for lookup.
My job is outlined below. If its not possible to get properties on an open file how do I re-engineer the job so I don't end up getting the properties but not the data rows (assuming I can't ReadExcel if the file is open for tFileProperties
ReadFolder -> ReadExcel->tMap(addSourceFileDataToRow) ->tMap(GetModifiedDate) ->
Read the file properties and cache them into memory for used later, change the job as below:
ReadFolder -> tfileProperties--tHashoutput--oncomponentok-
ReadExcel->tMap(addSourceFileDataToRow) ->tMap(GetModifiedDate) ->
Let me know if it works.
That didn't work. If I run in debug mode there are no rows coming in from the lookup hash flow so nothing to match against the flow from the tExcel. Thats even though there there is content read into the hashOutput
Talend named a Leader.
Kickstart your first data integration and ETL projects.
Part 2 of a series on Context Variables
Learn how to do cool things with Context Variables
Find out how to migrate from one database to another using the Dynamic schema