Page 1 of 1
Wait for file activity
Posted: Tue Jun 17, 2014 10:26 am
by lkomala
I am trying to pass file name in wait for file activity stage.
File name changes for every run.
I was trying to give *.txt. but it seams stage does not accept wildcard.
Can any one please help me.
Thanks
Posted: Tue Jun 17, 2014 11:53 am
by vamsi.4a6
I think you can use Output of Uservariable activity or Execute command activity output in Wait for file activity.
Posted: Tue Jun 17, 2014 12:01 pm
by chulett
Welcome aboard.
As you've found, the WFF stage does not support wildcards so you'll need some other mechanism. How are your shell scripting skills? You could script something equivalent and then use an Execute Command stage to run it. Some other approaches inside DataStage are noted
here and
here.
Posted: Tue Jun 17, 2014 12:13 pm
by lkomala
My first stage is to FTP the files to folder, second is checking whether the files came over to the folder, so using wait for file activity to watch for files if they appear my next process starts if not process ends and sends notification
Posted: Tue Jun 17, 2014 12:25 pm
by lkomala
My OS is windows
Posted: Tue Jun 17, 2014 1:03 pm
by chulett
Because of the underlying software DataStage uses, you can still use 'UNIX' scripts on a Windows DataStage server. That or replace all occurrences of "shell script" in my response with "batch file".
Posted: Wed Jun 18, 2014 3:33 am
by vamsi.4a6
lkomala wrote:My OS is windows
You can use MKS tool kit also.Use following link or google for more information
en.wikipedia.org/wiki/MKS_Toolkit
Posted: Wed Jun 18, 2014 7:12 am
by chulett
As noted.