Fonction SAP API_SEMBPS_VARIABLE_SET - Set Variable Values

Paramètre Reférence Type Long. Valeur par déf. Facultatif Description
IS_HIESEL UPC_YS_API_HIESEL u 105 X Hierarchy Node Selection
I_AREA UPC_AREA-AREA C 8 X Planning Area
I_NUMVALUE UPC_VAR_NUM_SEL-NUMVALUE P 16 X Numeric Value for Variables
I_VARIABLE UPC_VAR-VAR C 8 X Variable

Paramètre Reférence Type Long. Description
ES_RETURN BAPIRET2 u 548 Return Parameter
E_SUBRC SYST-SUBRC I 4 Return Code

Paramètre Reférence Long. Facultatif Description
ITK_HIEDEP UPC_YS_API_HIEDEP 104 X Values of Compound Characteristics
ITK_VARSEL UPC_YS_API_VARSEL 177 X Selection Condition for Variables

Functionality
With this function module

  • Restrictions for variable values can be executed

  • New variable values can be added (only if the variable is of the type
  • user-specific values)
    This functionality refers to the Set Variable function in theplanning workbench BPS0. Here one value from the pool of variable valuescan be set.
    The settings are only valid during the current planning session and canbe saved by calling up API_SEMBPS_POST.
    According to the type of the variable (field E_TYPE in the functionmodule API_SEMBPS_VARIABLE_GETDETAIL), the folowing fields must besupplied:
    • Type 'CHAR'

    • Table ITK_VARSEL is to be filled like the table ITK_CHASEL in functionmodule API_SEMBPS_ADHOCPACKAGE_SET. The field SEQNO is of no importancehere.
      • Type 'NUMBER'

      • The new numeric value is to be entered in field I_NUMVALUE.
        • Type 'HIERARCHY'

        • The hierarchy nodes are to be entered in the structure IS_HIESEL and -with compound characteristics - in the table ITK_HIEDEP . Theseparameters are normally filled by supplying them from an entry (of aSEQNO) from the tables ETK_HIESEL_ALL and ETK_HIEDEP_ALL of the moduleAPI_SEMBPS_VARIABLE_GETDETAIL.

          Example
          A variable on the characterierstic version (0VERSION) has the values V01and V02.
          If you want to set the version V02, you must fill a row as follows inthe table ITK_VARSEL:
          CHANM = '0VERSION'
          SIGN = 'I'
          OPTION = 'EQ'
          LOW = 'V02'
          If you want to add the version V03, you must fill a row as follows inthe table ITK_VARSEL:
          CHANM = '0VERSION'
          SIGN = 'I'
          OPTION = 'EQ'
          LOW = 'V03'