SAP /SAPAPO/DM_PROD_LOC_MAINTAIN Function Module for Inbound Processing, Creation and Changing of Forecast Orders
/SAPAPO/DM_PROD_LOC_MAINTAIN is a standard /sapapo/dm prod loc maintain SAP function module available within SAP R/3 or S/4 Hana systems, depending on your version and release level. It is used for Inbound Processing, Creation and Changing of Forecast Orders 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 /sapapo/dm prod loc maintain FM, simply by entering the name /SAPAPO/DM_PROD_LOC_MAINTAIN into the relevant SAP transaction such as SE37 or SE38.
Function Group: /SAPAPO/CIF_DDE
Program Name: /SAPAPO/SAPLCIF_DDE
Main Program: /SAPAPO/SAPLCIF_DDE
Appliation area: D
Release date: N/A
Mode(Normal, Remote etc): Remote-Enabled
Update:

Function /SAPAPO/DM_PROD_LOC_MAINTAIN 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 '/SAPAPO/DM_PROD_LOC_MAINTAIN'"Inbound Processing, Creation and Changing of Forecast Orders.
EXPORTING
* CF_DST_BSG = "
* RELNAME = "Name einer Hierarchie
TABLES
IT_REL_MATLOC = "
IT_REL_MATLOCX = "
* ET_RETURN = "
EXCEPTIONS
INIT_ERROR = 1 LOGSYS_ERROR = 2 BSG_ERROR = 3 USEREXIT_ERROR = 4 ODB_ERROR = 5 POSTING_ERROR = 6 LOGGING_ERROR = 7 INTERNAL_ERROR = 8
IMPORTING Parameters details for /SAPAPO/DM_PROD_LOC_MAINTAIN
CF_DST_BSG -
Data type: /SAPAPO/SYSDIR-LOGQSOptional: Yes
Call by Reference: No ( called with pass by value option)
RELNAME - Name einer Hierarchie
Data type: /SAPAPO/RELNAMEOptional: Yes
Call by Reference: No ( called with pass by value option)
TABLES Parameters details for /SAPAPO/DM_PROD_LOC_MAINTAIN
IT_REL_MATLOC -
Data type: /SAPAPO/CIF_REL_MATLOCOptional: No
Call by Reference: No ( called with pass by value option)
IT_REL_MATLOCX -
Data type: /SAPAPO/CIF_REL_MATLOCXOptional: No
Call by Reference: No ( called with pass by value option)
ET_RETURN -
Data type: BAPIRET2Optional: Yes
Call by Reference: No ( called with pass by value option)
EXCEPTIONS details
INIT_ERROR -
Data type:Optional: No
Call by Reference: No ( called with pass by value option)
LOGSYS_ERROR -
Data type:Optional: No
Call by Reference: No ( called with pass by value option)
BSG_ERROR -
Data type:Optional: No
Call by Reference: No ( called with pass by value option)
USEREXIT_ERROR -
Data type:Optional: No
Call by Reference: No ( called with pass by value option)
ODB_ERROR -
Data type:Optional: No
Call by Reference: No ( called with pass by value option)
POSTING_ERROR -
Data type:Optional: No
Call by Reference: No ( called with pass by value option)
LOGGING_ERROR -
Data type:Optional: No
Call by Reference: No ( called with pass by value option)
INTERNAL_ERROR -
Data type:Optional: No
Call by Reference: No ( called with pass by value option)
Copy and paste ABAP code example for /SAPAPO/DM_PROD_LOC_MAINTAIN 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_cf_dst_bsg | TYPE /SAPAPO/SYSDIR-LOGQS, " | |||
| lv_init_error | TYPE /SAPAPO/SYSDIR, " | |||
| lt_it_rel_matloc | TYPE STANDARD TABLE OF /SAPAPO/CIF_REL_MATLOC, " | |||
| lv_relname | TYPE /SAPAPO/RELNAME, " | |||
| lv_logsys_error | TYPE /SAPAPO/RELNAME, " | |||
| lt_it_rel_matlocx | TYPE STANDARD TABLE OF /SAPAPO/CIF_REL_MATLOCX, " | |||
| lv_bsg_error | TYPE /SAPAPO/CIF_REL_MATLOCX, " | |||
| lt_et_return | TYPE STANDARD TABLE OF BAPIRET2, " | |||
| lv_userexit_error | TYPE BAPIRET2, " | |||
| lv_odb_error | TYPE BAPIRET2, " | |||
| lv_posting_error | TYPE BAPIRET2, " | |||
| lv_logging_error | TYPE BAPIRET2, " | |||
| lv_internal_error | TYPE BAPIRET2. " |
|   CALL FUNCTION '/SAPAPO/DM_PROD_LOC_MAINTAIN' "Inbound Processing, Creation and Changing of Forecast Orders |
| EXPORTING | ||
| CF_DST_BSG | = lv_cf_dst_bsg | |
| RELNAME | = lv_relname | |
| TABLES | ||
| IT_REL_MATLOC | = lt_it_rel_matloc | |
| IT_REL_MATLOCX | = lt_it_rel_matlocx | |
| ET_RETURN | = lt_et_return | |
| EXCEPTIONS | ||
| INIT_ERROR = 1 | ||
| LOGSYS_ERROR = 2 | ||
| BSG_ERROR = 3 | ||
| USEREXIT_ERROR = 4 | ||
| ODB_ERROR = 5 | ||
| POSTING_ERROR = 6 | ||
| LOGGING_ERROR = 7 | ||
| INTERNAL_ERROR = 8 | ||
| . " /SAPAPO/DM_PROD_LOC_MAINTAIN | ||
ABAP code using 7.40 inline data declarations to call FM /SAPAPO/DM_PROD_LOC_MAINTAIN
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.| "SELECT single LOGQS FROM /SAPAPO/SYSDIR INTO @DATA(ld_cf_dst_bsg). | ||||
Search for further information about these or an SAP related objects