Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
I am using FtpGet to extract or retrieve a file from the ftp and loading into the database and before that i am storing in a local folder.
So before i use tfilecopy to the local i would like to perform a check wherein if the file already exists in the local folder skip or ignore the next steps,if they dont exist then only write (tfilecopy) to the local folder.
So basically i want to iterate through the list of files in the local folder based on the one i am retrieving using
((String)globalMap.get("tFileList_1_CURRENT_FILEPATH")) dynamically and check if that file exists or not amongst the list of all the other files in that folder and perform the action.
Please suggest
Hi Harryishs,
where exactly is your tfilecopy component ? Could you please paste here a screenshot of your flow ? Is it something like this ?:
tFTPFileList >iterate> tFTPGet >OnSubjobOk>tFileList>iterate>tfileInputDelimited>row>tdbOutput>OnComponentOk>tfilecopy
@pakapi_
Thanks for the tip,but i am trying to check if a file retrieved from the ftp site either exists in the logfile (an excel file which has the filename retrieved prior) or from a database table if that filename already exists.
I found the latter approach more viable than cross-checking by reading from a file,so i took the database route to see if the file i am reading from ftp site already exists in the db tabl,skip it.
if the file doesnt exist copy the file onto the destination folder.
But here i am unable to see the dboutput in the log...any idea would be appreciated?
Even though filename is getting displayed in tlogrow1,i cannot see anything after querying the db for results
What is in tDBInput ? Have you defined schema ? Please paste here tDBInput configuration tab.