‎2006 Nov 21 9:03 PM
I am executing the following command from a abap program to execute a Unix Script. The script executes successfully but it comes back to the program with a sy-subrc return code of -1????? Anyone have any ideas? We are on 4.6c
Thank You
&----
*& Form EXECUTE_UNIX_COMMAND *
&----
*
----
form execute_unix_command.
CALL 'SYSTEM' ID 'COMMAND' FIELD app_script
ID 'TAB' FIELD TABL-SYS.
‎2006 Nov 21 10:20 PM
Hi,
Have you tried executing the external commands using the SM69 and SM49?
I usually do this.
In SM69, create a command for your shell script and than you can call this command from your program using the FM: SXPG_COMMAND_EXECUTE
Hope this helps,
Sumant.
‎2006 Nov 21 9:30 PM
Hi Joe,
Check the Below program, you will get this program in latest versions from 4.6c...
RSBDCOS0---->subroutine EXEC
*******************************************************
look OSS Note 9391 for more info
Regards,
Srinivas
‎2006 Nov 21 10:20 PM
Hi,
Have you tried executing the external commands using the SM69 and SM49?
I usually do this.
In SM69, create a command for your shell script and than you can call this command from your program using the FM: SXPG_COMMAND_EXECUTE
Hope this helps,
Sumant.
‎2006 Nov 27 3:20 PM
Srinivas & Sumant - Thank you both for your help. It looks like Sumants suggestion will do what I need to do.
Thanks,
Joe