R3_SET_BDCDATA

Use the R3_SET_BDCDATE script element to define Batch Data Communication (BDC) data. You can assign values to screen fields in batch mode. The SAP Agent stores these assignments in an internal table. The R3_CALL_TRANSACTION script element then starts the actual processing, and the internal table is reset.

First, you call R3_SET_BDCDATA with the parameters PROGRAM=, DYNPRO= , and DYBEGIN=. In the next step, you use the parameters FNAM= and FVAL= to assign values to selected fields. You can repeat these definitions of BDC data for the same or other screen forms as often as required.

Transaction: -
Interface: AE

Syntax

R3_SET_BDCDATA

    PROGRAM=...
    ,DYNPRO=...
    [,DYBEGIN=...]

Parameters

  • R3_SET_BDCDATA
    Defines BDC data

  • PROGRAM=
    Program name, a maximum of 40 characters is allowed
    Format: script literal

  • DYNPRO=
    Four-digit screen number
    Format:
    script literal

  • DYBEGIN=
    (Optional) Indicates whether a new screen form should start
    Format:
    script literal
    Allowed values:

    • "" (default)
      No new screen form starts
    • X
      A new screen form starts

R3_SET_BDCDATA

    ,FNAME=...
    ,FVAL=...

Parameters

  • FNAM=
    Field name, a maximum of 132 characters is allowed.
    Format: script literal

  • FVAL=
    The value that should be assigned to the field, a maximum of 132 characters is allowed.
    Format: script literal

Examples

The following example fills the screen forms of the entire SA38 transaction with data. The screens are called in the given order and the fields obtain values. Then, the SA38 transaction starts and updates the data.

R3_SET_BDCDATA PROGRAM="SAPMS38M", DYNPRO="0101", DYBEGIN="X"
R3_SET_BDCDATA FNAM="BDC_OKCODE", FVAL="=SSET"
R3_SET_BDCDATA FNAM="RS38M-PROGRAM", FVAL="RSEINB00"
R3_SET_BDCDATA PROGRAM="SAPLSVAR", DYNPRO="0302", DYBEGIN="X"
R3_SET_BDCDATA FNAM="BDC_OKCODE", FVAL="=CHNG"
R3_SET_BDCDATA FNAM="RSVAR-VARIANT", FVAL="UM-V1"
R3_SET_BDCDATA FNAM="RSVAR-FLAG1", FVAL="X"
R3_SET_BDCDATA PROGRAM="RSEINB00", DYNPRO="1000", DYBEGIN="X"
R3_SET_BDCDATA FNAM="BDC_OKCODE", FVAL="=SAVE"
R3_SET_BDCDATA FNAM="P_FILE", FVAL="test.txt"
R3_SET_BDCDATA PROGRAM="RSEINB00", DYNPRO="1000", DYBEGIN="X"
R3_SET_BDCDATA FNAM="BDC_OKCODE", FVAL="=VBAC"
R3_SET_BDCDATA PROGRAM="SAPLSVAR", DYNPRO="0302", DYBEGIN="X"
R3_SET_BDCDATA FNAM="BDC_OKCODE", FVAL="/EBACK"
R3_SET_BDCDATA PROGRAM="SAPMS38M", DYNPRO="0101", DYBEGIN="X"
R3_SET_BDCDATA FNAM="BDC_OKCODE", FVAL="=BACK"
R3_CALL_TRANSACTION CODE="SA38", UPDATE="S"

See also:

seealso

About SAP JCL