Originally posted by: john.gibby
This isn't too difficult, but I'll have to make some assumptions. For each filename in the control file, set up an output card to determine if the file exists in map directory, and if so, to read it in.
Input Card# 1
text file w/ newline delim: Control_File (with 3 number of filenames)
Output Card# 1
text file w/ newline delim: =VALID(GET("FILE",WORD(CONTROL_FILE,"<NL>",1)),"FileNotFound")
Output Card# 2
text file w/ newline delim: =VALID(GET("FILE",WORD(CONTROL_FILE,"<NL>",2)),"FileNotFound")
Output Card# 3
text file w/ newline delim: =VALID(GET("FILE",WORD(CONTROL_FILE,"<NL>",3)),"FileNotFound")
If any of your output cards equal "FileNotFound", then the file does not exist in the map directory. However, the GET() function only reads in the file as a text object. It cannot be validated on-the-fly to some other type tree definition. Thus, you would have to pass those objects on to another map for the to be validated by their correct type trees. If all the files exist, run the map, otherwise handle accordingly.
John
#IBMSterlingTransformationExtender#IBM-Websphere-Transformation-Extender#DataExchange