SAP SELECT_POSITIONS Function Module for PRICAT Inbound: Select Items
SELECT_POSITIONS is a standard select positions SAP function module available within SAP R/3 or S/4 Hana systems, depending on your version and release level. It is used for PRICAT Inbound: Select Items processing and below is the pattern details for this FM, showing its interface including any import and export parameters, exceptions etc. there is also a full "cut and paste" ABAP pattern code example, along with implementation ABAP coding, documentation and contribution comments specific to this or related objects.
See here to view full function module documentation and code listing for select positions FM, simply by entering the name SELECT_POSITIONS into the relevant SAP transaction such as SE37 or SE38.
Function Group: WRF_RFC_INTERFACE
Program Name: SAPLWRF_RFC_INTERFACE
Main Program: SAPLWRF_RFC_INTERFACE
Appliation area:
Release date: N/A
Mode(Normal, Remote etc): Remote-Enabled
Update:

Function SELECT_POSITIONS pattern details
In-order to call this FM within your sap programs, simply using the below ABAP pattern details to trigger the function call...or see the full ABAP code listing at the end of this article. You can simply cut and paste this code into your ABAP progrom as it is, including variable declarations.CALL FUNCTION 'SELECT_POSITIONS'"PRICAT Inbound: Select Items.
EXPORTING
IT_CATALOGUE = "Purchasing List: Header Data
I_PROC_STATUS = "Price Catalog Inbound: Processing Status
* IT_EAN_RANGE = "Range Table: EAN
* IT_DATE_RANGE = "Range Table: Date
* IT_MATL_TYPE_RANGE = "Range Table: Material Type
* IT_MATL_GROUP_RANGE = "Range Table: Material Group
* IT_MATL_CAT_RANGE = "Range Table: Material Category
* IT_DESCRIPTION_RANGE = "Range Table: Material Short Text
I_LOCKED = "General Flag
I_UNLOCKED = "General Flag
IMPORTING
ET_POSITION = "PRICAT Inbound: Item Data for Purchasing List
IMPORTING Parameters details for SELECT_POSITIONS
IT_CATALOGUE - Purchasing List: Header Data
Data type: WRF_PURCH_CATHEAD_TTYOptional: No
Call by Reference: No ( called with pass by value option)
I_PROC_STATUS - Price Catalog Inbound: Processing Status
Data type: WRF_PROCVALUEOptional: No
Call by Reference: No ( called with pass by value option)
IT_EAN_RANGE - Range Table: EAN
Data type: WRF_EAN_RTTYOptional: Yes
Call by Reference: No ( called with pass by value option)
IT_DATE_RANGE - Range Table: Date
Data type: WRF_DATE_RTTYOptional: Yes
Call by Reference: No ( called with pass by value option)
IT_MATL_TYPE_RANGE - Range Table: Material Type
Data type: WRF_MATL_TYPE_RTTYOptional: Yes
Call by Reference: No ( called with pass by value option)
IT_MATL_GROUP_RANGE - Range Table: Material Group
Data type: WRF_MATL_GROUP_RTTYOptional: Yes
Call by Reference: No ( called with pass by value option)
IT_MATL_CAT_RANGE - Range Table: Material Category
Data type: WRF_MATL_CAT_RTTYOptional: Yes
Call by Reference: No ( called with pass by value option)
IT_DESCRIPTION_RANGE - Range Table: Material Short Text
Data type: WRF_MAKTX_RTTYOptional: Yes
Call by Reference: No ( called with pass by value option)
I_LOCKED - General Flag
Data type: FLAGOptional: No
Call by Reference: No ( called with pass by value option)
I_UNLOCKED - General Flag
Data type: FLAGOptional: No
Call by Reference: No ( called with pass by value option)
EXPORTING Parameters details for SELECT_POSITIONS
ET_POSITION - PRICAT Inbound: Item Data for Purchasing List
Data type: WRF_PURCH_CATPOS_TTYOptional: No
Call by Reference: No ( called with pass by value option)
Copy and paste ABAP code example for SELECT_POSITIONS Function Module
The ABAP code below is a full code listing to execute function module POPUP_TO_CONFIRM including all data declarations. The code uses the original data declarations rather than 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 newer method of declaring data variables on the fly. 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), which i why i have stuck to the origianl for this example.| DATA: | ||||
| lv_et_position | TYPE WRF_PURCH_CATPOS_TTY, " | |||
| lv_it_catalogue | TYPE WRF_PURCH_CATHEAD_TTY, " | |||
| lv_i_proc_status | TYPE WRF_PROCVALUE, " | |||
| lv_it_ean_range | TYPE WRF_EAN_RTTY, " | |||
| lv_it_date_range | TYPE WRF_DATE_RTTY, " | |||
| lv_it_matl_type_range | TYPE WRF_MATL_TYPE_RTTY, " | |||
| lv_it_matl_group_range | TYPE WRF_MATL_GROUP_RTTY, " | |||
| lv_it_matl_cat_range | TYPE WRF_MATL_CAT_RTTY, " | |||
| lv_it_description_range | TYPE WRF_MAKTX_RTTY, " | |||
| lv_i_locked | TYPE FLAG, " | |||
| lv_i_unlocked | TYPE FLAG. " |
|   CALL FUNCTION 'SELECT_POSITIONS' "PRICAT Inbound: Select Items |
| EXPORTING | ||
| IT_CATALOGUE | = lv_it_catalogue | |
| I_PROC_STATUS | = lv_i_proc_status | |
| IT_EAN_RANGE | = lv_it_ean_range | |
| IT_DATE_RANGE | = lv_it_date_range | |
| IT_MATL_TYPE_RANGE | = lv_it_matl_type_range | |
| IT_MATL_GROUP_RANGE | = lv_it_matl_group_range | |
| IT_MATL_CAT_RANGE | = lv_it_matl_cat_range | |
| IT_DESCRIPTION_RANGE | = lv_it_description_range | |
| I_LOCKED | = lv_i_locked | |
| I_UNLOCKED | = lv_i_unlocked | |
| IMPORTING | ||
| ET_POSITION | = lv_et_position | |
| . " SELECT_POSITIONS | ||
ABAP code using 7.40 inline data declarations to call FM SELECT_POSITIONS
The below ABAP code uses the newer in-line data declarations. This allows you to see the coding differences/benefits of the later inline syntax. Please note some of the newer syntax below, such as the @DATA is not available until 4.70 EHP 8.Search for further information about these or an SAP related objects