Event monitor running package which run external app

More
4 years 2 months ago #19331 by aldridge44
Hi, Have been testing to try and make this work - got an event monitor setup which is looking for a file in a specified folder - the event is triggered and seems to run the package but the external app runs according to the log but does nothing. - I am testing just using a batch file that copies a file from one folder to another. I have proved the functionality of the bat file but the missing link is the external app call apparently not actually doing anything? Any idea what I have done wrong?
Attachments:

Please Log in or Create an account to join the conversation.

More
4 years 2 months ago #19332 by aldridge44
Ignore the bat file actions - a space had crept into the file name...... but am still trying to get this to work with running an external exe file which seems to do nothing when invoked by ETL - can run the bat file to invoke it from command line or Explorer and it operates OK.

Please Log in or Create an account to join the conversation.

More
4 years 2 months ago #19333 by admin
Most likely you script is waiting for user input.
Like:
Are you sure that you want to delete file Y/N
Are you sure that you want to overwrite a file?
The easiest war to find out what it is the problem is to redirect all output into the log file
test.bat > test.txt 2>&1

Or you can just use file operation action
www.etl-tools.com/wiki/aetle/packages/file_operation_action

Mike
ETL Architect

Please Log in or Create an account to join the conversation.

More
4 years 2 months ago #19335 by aldridge44
Thanks - that was just an example (a bad one!) I was using to test - I am actually attempting to run an external app using a batch file (which does work external to ETL) but the app doesn't run - the other commands in the batch file operate. Batch file as below:

cd C:\FTP\Export\MJA Utils\System4_V56Cli\Da Conti System4 V56\S4Client\bin
START s4.exe user=SYSADM, password=sysadm, appname=CILAS, startprog=ucp0021
copy c:\ftp\test\In\test.txt c:\ftp\test\Out\test.txt
del c:\ftp\test\In\test.txt
exit

The commands after the START command are carried out so the batch file is running but just not executing the START command. It runs if I call the bat file from command prompt (elevated or not) or through explorer. Suspect it is the way you are executing the .bat file? Can this be configured?

Please Log in or Create an account to join the conversation.

More
4 years 2 months ago #19336 by admin
I suspect the software is unable to find s4.exe file

Mike
ETL Architect

Please Log in or Create an account to join the conversation.

More
4 years 2 months ago #19337 by aldridge44
Am only running it through a batch file because it doesn't work if I call it directly with the required runtime parameters.

The full string I am using in the application to run window is:

"C:\FTP\Export\MJA Utils\System4_V56Cli\Da Conti System4 V56\S4Client\bin\s4.exe" user=SYSADM, password=sysadm, appname=CILAS, startprog=ucp0021

Log viewer result of this is as attached.

Presume it is not possible to run the external program like this?
Attachments:

Please Log in or Create an account to join the conversation.