January 02, 2012, 01:50 AM
RamanathanHow to call a unix shell script in the process flow?
Hi All,
I need to run a unix shell script at the end of the process flow. Please let me know how to call a unix shell script in a process flow?
Thanks in advance.
January 02, 2012, 08:35 AM
dhagenUse a RunCmdAgentSorry. Just realized that you are using iDM not iSM.
Two ways. In both cases, you need to create a stored proc:
If you do not need to know the return code then use the exclamation sign "!" to shell to the os:
! ls -al | grep fex
If you need to know the return code from your script, then:
-SET &MYRETURN=SYSTEM(17,'ls -al | grep fex','D3');
-IF &MYRETURN NE 0 THEN do-something;
This message has been edited. Last edited by: dhagen,