SAP Function Modules

BAPI_REQUIREMENT_GET_LIST SAP Function module - List Requirement Coverage Requests/Requisitions







BAPI_REQUIREMENT_GET_LIST 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 BAPI_REQUIREMENT_GET_LIST into the relevant SAP transaction such as SE37 or SE80.

Associated Function Group: MEWR
Released Date: 17.09.1997
Processing type: Remote-Enabled
remote enabled module settings


Pattern for FM BAPI_REQUIREMENT_GET_LIST - BAPI REQUIREMENT GET LIST





CALL FUNCTION 'BAPI_REQUIREMENT_GET_LIST' "List Requirement Coverage Requests/Requisitions
* EXPORTING
*   preq_name =                 " bapimmpara-preq_name  Name of Requisitioner (Requester)/Entering User
*   preq_date =                 " bapimmpara-preq_date  Requisition/Request Date
*   open_items =                " bapimmpara-selection  Indicator: Open Requirement Coverage Requests Only
*   closed_items =              " bapimmpara-selection  Indicator: Closed Requirement Coverage Requests Only
*   rel_group =                 " bapimmpara-rel_group  Release Group for Collective Release
*   rel_code =                  " bapimmpara-rel_code  Release Code for Collective Release
*   items_for_release = 'X'     " bapimmpara-selection  Indicator: Purchase Requisitions Awaiting Release Only
  TABLES
    requirement_items =         " bapieban      Table of Requirement Coverage Requests/Purchase Requisitions
  EXCEPTIONS
    PREQ_NAME_MISSING = 1       "               Requester Missing from Status Display
    STATUS_MISSING = 2          "               Open/Closed Indicator Missing from Status Display
    REL_CODE_MISSING = 3        "               Release Code Missing
    REL_AUTH_CHECK_FAILED = 4   "               No Release Authorization
    .  "  BAPI_REQUIREMENT_GET_LIST

ABAP code example for Function Module BAPI_REQUIREMENT_GET_LIST





The ABAP code below is a full code listing to execute function module BAPI_REQUIREMENT_GET_LIST 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_requirement_items  TYPE STANDARD TABLE OF BAPIEBAN,"TABLES PARAM
wa_requirement_items  LIKE LINE OF it_requirement_items .


DATA(ld_preq_name) = some text here

DATA(ld_preq_date) = 20210129

DATA(ld_open_items) = some text here

DATA(ld_closed_items) = some text here

DATA(ld_rel_group) = some text here

DATA(ld_rel_code) = some text here

DATA(ld_items_for_release) = some text here

"populate fields of struture and append to itab
append wa_requirement_items to it_requirement_items. . CALL FUNCTION 'BAPI_REQUIREMENT_GET_LIST' * EXPORTING * preq_name = ld_preq_name * preq_date = ld_preq_date * open_items = ld_open_items * closed_items = ld_closed_items * rel_group = ld_rel_group * rel_code = ld_rel_code * items_for_release = ld_items_for_release TABLES requirement_items = it_requirement_items EXCEPTIONS PREQ_NAME_MISSING = 1 STATUS_MISSING = 2 REL_CODE_MISSING = 3 REL_AUTH_CHECK_FAILED = 4 . " BAPI_REQUIREMENT_GET_LIST
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 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_preq_name  TYPE BAPIMMPARA-PREQ_NAME ,
it_requirement_items  TYPE STANDARD TABLE OF BAPIEBAN ,
wa_requirement_items  LIKE LINE OF it_requirement_items,
ld_preq_date  TYPE BAPIMMPARA-PREQ_DATE ,
ld_open_items  TYPE BAPIMMPARA-SELECTION ,
ld_closed_items  TYPE BAPIMMPARA-SELECTION ,
ld_rel_group  TYPE BAPIMMPARA-REL_GROUP ,
ld_rel_code  TYPE BAPIMMPARA-REL_CODE ,
ld_items_for_release  TYPE BAPIMMPARA-SELECTION .


ld_preq_name = some text here

"populate fields of struture and append to itab
append wa_requirement_items to it_requirement_items.

ld_preq_date = 20210129

ld_open_items = some text here

ld_closed_items = some text here

ld_rel_group = some text here

ld_rel_code = some text here

ld_items_for_release = some text here

SAP Documentation for FM BAPI_REQUIREMENT_GET_LIST


This method allows you to generate the following lists:
...See here for full SAP fm documentation

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 BAPI_REQUIREMENT_GET_LIST or its description.