SAP Function Modules

REQUIREMENTS_SPLITTING SAP Function module







REQUIREMENTS_SPLITTING is a standard SAP function module available within R/3 SAP systems depending on your version and release level. Below is the pattern details for this FM showing its interface including any import and export parameters, exceptions etc as well as any documentation contributions (Comments) specific to the object.

See here to view full function module documentation and code listing, simply by entering the name REQUIREMENTS_SPLITTING into the relevant SAP transaction such as SE37 or SE80.

Associated Function Group: M60S
Released Date: Not Released
Processing type: Normal fucntion module
Normal function module settings


Pattern for FM REQUIREMENTS_SPLITTING - REQUIREMENTS SPLITTING





CALL FUNCTION 'REQUIREMENTS_SPLITTING' "
  EXPORTING
*   idatub = '00000000'         " rm60x-edatbi
    idatuv =                    " rm60x-edatvi
*   ientlu =                    " pbet-entlu
    imeins =                    " pbpt-meins
*   iperiv =                    " pbpt-periv
    iperkz =                    " rm60e-entli
*   iperxx =                    " pbet-perxx
    isplkz =                    " rm60e-auten
    isplmng =                   " rm60e-plnmg
    iwerks =                    " pbpt-werks
*   iquant =                    " rm60e-ruwert
*   imrppp =                    " t439i-mrppp
*   ivertl =                    " t437v-vertl
*   icuobj =                    " pbed-cuobj
  TABLES
    fspbet =                    " apet
  EXCEPTIONS
    CALENDAR_NOT_FOUND = 1      "
    DATE_AFTER_RANGE = 2        "
    DATE_BEFORE_RANGE = 3       "
    DATE_INVALID = 4            "
    T009B_NOT_FOUND = 5         "
    WERK_NOT_FOUND = 6          "
    .  "  REQUIREMENTS_SPLITTING

ABAP code example for Function Module REQUIREMENTS_SPLITTING





The ABAP code below is a full code listing to execute function module REQUIREMENTS_SPLITTING including all data declarations. The code uses the latest in-line data DECLARATION SYNTAX but I have included an ABAP code snippet at the end to show how declarations would look using the original method of declaring data variables up front. This will allow you to compare and fully understand the new inline method. Please note some of the newer syntax such as the @DATA is not available until a later 4.70 service pack (SP8).

DATA:
it_fspbet  TYPE STANDARD TABLE OF APET,"TABLES PARAM
wa_fspbet  LIKE LINE OF it_fspbet .


DATA(ld_idatub) = 20210129

DATA(ld_idatuv) = 20210129

DATA(ld_ientlu) = some text here

DATA(ld_imeins) = Check type of data required

DATA(ld_iperiv) = some text here

DATA(ld_iperkz) = some text here

DATA(ld_iperxx) = some text here

DATA(ld_isplkz) = some text here

DATA(ld_isplmng) = Check type of data required

DATA(ld_iwerks) = some text here

DATA(ld_iquant) = Check type of data required

SELECT single MRPPP
FROM T439I
INTO @DATA(ld_imrppp).


SELECT single VERTL
FROM T437V
INTO @DATA(ld_ivertl).


SELECT single CUOBJ
FROM PBED
INTO @DATA(ld_icuobj).


"populate fields of struture and append to itab
append wa_fspbet to it_fspbet. . CALL FUNCTION 'REQUIREMENTS_SPLITTING' EXPORTING * idatub = ld_idatub idatuv = ld_idatuv * ientlu = ld_ientlu imeins = ld_imeins * iperiv = ld_iperiv iperkz = ld_iperkz * iperxx = ld_iperxx isplkz = ld_isplkz isplmng = ld_isplmng iwerks = ld_iwerks * iquant = ld_iquant * imrppp = ld_imrppp * ivertl = ld_ivertl * icuobj = ld_icuobj TABLES fspbet = it_fspbet EXCEPTIONS CALENDAR_NOT_FOUND = 1 DATE_AFTER_RANGE = 2 DATE_BEFORE_RANGE = 3 DATE_INVALID = 4 T009B_NOT_FOUND = 5 WERK_NOT_FOUND = 6 . " REQUIREMENTS_SPLITTING
IF SY-SUBRC EQ 0. "All OK ELSEIF SY-SUBRC EQ 1. "Exception "Add code for exception here ELSEIF SY-SUBRC EQ 2. "Exception "Add code for exception here ELSEIF SY-SUBRC EQ 3. "Exception "Add code for exception here ELSEIF SY-SUBRC EQ 4. "Exception "Add code for exception here ELSEIF SY-SUBRC EQ 5. "Exception "Add code for exception here ELSEIF SY-SUBRC EQ 6. "Exception "Add code for exception here ENDIF.







ABAP code to compare 7.40 inline data declaration with original syntax

The below ABAP code uses the older none in-line data declarations. This allows you to see the coding differences/benefits of the later inline syntax. It may also be useful if you are using an older version of SAP as some of the newer syntax above, such as the @DATA is not available until 4.70 EHP 8.

DATA:
ld_idatub  TYPE RM60X-EDATBI ,
it_fspbet  TYPE STANDARD TABLE OF APET ,
wa_fspbet  LIKE LINE OF it_fspbet,
ld_idatuv  TYPE RM60X-EDATVI ,
ld_ientlu  TYPE PBET-ENTLU ,
ld_imeins  TYPE PBPT-MEINS ,
ld_iperiv  TYPE PBPT-PERIV ,
ld_iperkz  TYPE RM60E-ENTLI ,
ld_iperxx  TYPE PBET-PERXX ,
ld_isplkz  TYPE RM60E-AUTEN ,
ld_isplmng  TYPE RM60E-PLNMG ,
ld_iwerks  TYPE PBPT-WERKS ,
ld_iquant  TYPE RM60E-RUWERT ,
ld_imrppp  TYPE T439I-MRPPP ,
ld_ivertl  TYPE T437V-VERTL ,
ld_icuobj  TYPE PBED-CUOBJ .


ld_idatub = 20210129

"populate fields of struture and append to itab
append wa_fspbet to it_fspbet.

ld_idatuv = 20210129

ld_ientlu = some text here

ld_imeins = Check type of data required

ld_iperiv = some text here

ld_iperkz = some text here

ld_iperxx = some text here

ld_isplkz = some text here

ld_isplmng = Check type of data required

ld_iwerks = some text here

ld_iquant = Check type of data required

SELECT single MRPPP
FROM T439I
INTO ld_imrppp.


SELECT single VERTL
FROM T437V
INTO ld_ivertl.


SELECT single CUOBJ
FROM PBED
INTO ld_icuobj.

Contribute (Add Comments)

Please help keep this info upto date and use the comments section below to add useful hints, tips and information specific to this SAP function. This will then be available for you and other users to easily find by simply searching on the object name REQUIREMENTS_SPLITTING or its description.