How can I use tFileExist component in Talend?

user1805523 picture user1805523 · Jan 22, 2013 · Viewed 15.3k times · Source

Using Talend, I want to verify if there is a file named ListePS.xls in my D:/ to do some treatment else nothing.

How do I check if file exists in Talend?

Answer

amine ameur picture amine ameur · Jan 27, 2013

you must use the component tFileExist with two outputs IF:

 ((Boolean) globalMap.get ("tFileExist_1_EXISTS")) for the case 1(File existence)
 ! ((Boolean) globalMap.get ("tFileExist_1_EXISTS")) for case 2 (non-existence of file)