<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: SXPG_COMMAND_EXECUTE - need help in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/sxpg-command-execute-need-help/m-p/2248747#M485807</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Using this function module, you can check the authorization of a user to execute a particular external command and run the command:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;With the arguments specified in ADDITIONAL_PARAMETERS&lt;/P&gt;&lt;P&gt;On the target host system defined by OPERATINGSYSTEM and TARGETSYSTEM&lt;/P&gt;&lt;P&gt;If an SAP profile parameter is inserted in the portion of the command stored in the database, then the value of this parameter is substituted into the command. If an SAP application server is active on the target system (TARGETSYSTEM), then the profile parameter values are read from the profile that is active on that system. No parameter substitution is made in ADDITIONAL_PARAMETERS.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;After substitution, the command is checked for the presence of "dangerous" characters such as the semicolon ( ; ) on UNIX systems.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If an additional "security function module" is specified in the command definition, this function module is also called in the course of processingebenfalls. This function module can prevent execution of the command.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If the authorization checks complete successfully, the command is run on the target host system.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 21 May 2007 03:52:19 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2007-05-21T03:52:19Z</dc:date>
    <item>
      <title>SXPG_COMMAND_EXECUTE - need help</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/sxpg-command-execute-need-help/m-p/2248746#M485806</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello Friends,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please explain me the functionality of this program.&lt;/P&gt;&lt;P&gt;-&lt;/P&gt;&lt;HR originaltext="---------------------------------------------------------------------------------" /&gt;&lt;P&gt;REPORT ZABC.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;PARAMETER PCOMMAND(18) DEFAULT 'zw1001'.&lt;/P&gt;&lt;P&gt;DATA: BEGIN  OF PROTOCOL OCCURS 0.&lt;/P&gt;&lt;P&gt;        INCLUDE STRUCTURE BTCXPM.&lt;/P&gt;&lt;P&gt;DATA: END OF PROTOCOL.&lt;/P&gt;&lt;P&gt;DATA:  STATUS_00 LIKE  BTCXP3-EXITSTAT.&lt;/P&gt;&lt;P&gt;DATA: XCOMMAND LIKE SXPGCOTABE-NAME.&lt;/P&gt;&lt;P&gt;DATA: ADDI_PARA LIKE SXPGCOLIST-PARAMETERS.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;   MOVE PCOMMAND TO XCOMMAND.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;   CLEAR   STATUS_00.&lt;/P&gt;&lt;P&gt;   CALL FUNCTION 'SXPG_COMMAND_EXECUTE'&lt;/P&gt;&lt;P&gt;        EXPORTING&lt;/P&gt;&lt;P&gt;             COMMANDNAME                   = XCOMMAND&lt;/P&gt;&lt;P&gt;        IMPORTING&lt;/P&gt;&lt;P&gt;             STATUS                        = STATUS_00&lt;/P&gt;&lt;P&gt;        TABLES&lt;/P&gt;&lt;P&gt;             EXEC_PROTOCOL                 = PROTOCOL&lt;/P&gt;&lt;P&gt;        EXCEPTIONS&lt;/P&gt;&lt;P&gt;             NO_PERMISSION                 = 1&lt;/P&gt;&lt;P&gt;             COMMAND_NOT_FOUND             = 2&lt;/P&gt;&lt;P&gt;             PARAMETERS_TOO_LONG           = 3&lt;/P&gt;&lt;P&gt;             SECURITY_RISK                 = 4&lt;/P&gt;&lt;P&gt;             WRONG_CHECK_CALL_INTERFACE    = 5&lt;/P&gt;&lt;P&gt;             PROGRAM_START_ERROR           = 6&lt;/P&gt;&lt;P&gt;             PROGRAM_TERMINATION_ERROR     = 7&lt;/P&gt;&lt;P&gt;             X_ERROR                       = 8&lt;/P&gt;&lt;P&gt;             PARAMETER_EXPECTED            = 9&lt;/P&gt;&lt;P&gt;             TOO_MANY_PARAMETERS           = 10&lt;/P&gt;&lt;P&gt;             ILLEGAL_COMMAND               = 11&lt;/P&gt;&lt;P&gt;             WRONG_ASYNCHRONOUS_PARAMETERS = 12&lt;/P&gt;&lt;P&gt;             CANT_ENQ_TBTCO_ENTRY          = 13&lt;/P&gt;&lt;P&gt;             JOBCOUNT_GENERATION_ERROR     = 14&lt;/P&gt;&lt;P&gt;             OTHERS                        = 15.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;WRITE: / SY-SUBRC.&lt;/P&gt;&lt;P&gt;WRITE: / STATUS_00.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;LOOP AT PROTOCOL.&lt;/P&gt;&lt;P&gt;   WRITE: / PROTOCOL.&lt;/P&gt;&lt;P&gt;ENDLOOP.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Shreekant&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 21 May 2007 03:04:18 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/sxpg-command-execute-need-help/m-p/2248746#M485806</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-05-21T03:04:18Z</dc:date>
    </item>
    <item>
      <title>Re: SXPG_COMMAND_EXECUTE - need help</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/sxpg-command-execute-need-help/m-p/2248747#M485807</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Using this function module, you can check the authorization of a user to execute a particular external command and run the command:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;With the arguments specified in ADDITIONAL_PARAMETERS&lt;/P&gt;&lt;P&gt;On the target host system defined by OPERATINGSYSTEM and TARGETSYSTEM&lt;/P&gt;&lt;P&gt;If an SAP profile parameter is inserted in the portion of the command stored in the database, then the value of this parameter is substituted into the command. If an SAP application server is active on the target system (TARGETSYSTEM), then the profile parameter values are read from the profile that is active on that system. No parameter substitution is made in ADDITIONAL_PARAMETERS.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;After substitution, the command is checked for the presence of "dangerous" characters such as the semicolon ( ; ) on UNIX systems.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If an additional "security function module" is specified in the command definition, this function module is also called in the course of processingebenfalls. This function module can prevent execution of the command.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If the authorization checks complete successfully, the command is run on the target host system.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 21 May 2007 03:52:19 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/sxpg-command-execute-need-help/m-p/2248747#M485807</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-05-21T03:52:19Z</dc:date>
    </item>
  </channel>
</rss>

