SAP MARC_SOBSK Function Module for NOTRANSL: Prf. Sonderbeschaffungsschl. für die Kalkulation
MARC_SOBSK is a standard marc sobsk SAP function module available within SAP R/3 or S/4 Hana systems, depending on your version and release level. It is used for NOTRANSL: Prf. Sonderbeschaffungsschl. für die Kalkulation 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 marc sobsk FM, simply by entering the name MARC_SOBSK into the relevant SAP transaction such as SE37 or SE38.
Function Group: MG11
Program Name: SAPLMG11
Main Program: SAPLMG11
Appliation area: M
Release date: N/A
Mode(Normal, Remote etc): Normal Function Module
Update:

Function MARC_SOBSK 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 'MARC_SOBSK'"NOTRANSL: Prf. Sonderbeschaffungsschl. für die Kalkulation.
EXPORTING
WMARC_SOBSK = "Special Procurement Type for Costing
* P_MESSAGE = ' ' "For message type conversion
WMARC_SOBSL = "Special procurement type
WMARC_WERKS = "Plant
WMARC_STLAL = "Alternative BOM
WMARC_STLAN = "BOM Usage
WMARC_PLNNR = "Key for Task List Group
WMARC_APLAL = "Group Counter
WMARC_PLNTY = "Task List Type
WRMMG1_MTART = "Material Type
IMPORTING
WMARC_SOBSK = "Special Procurement Type for Costing
IMPORTING Parameters details for MARC_SOBSK
WMARC_SOBSK - Special Procurement Type for Costing
Data type: MARC-SOBSKOptional: No
Call by Reference: No ( called with pass by value option)
P_MESSAGE - For message type conversion
Data type: RMMG08_012-MSGTYPDefault: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)
WMARC_SOBSL - Special procurement type
Data type: MARC-SOBSLOptional: No
Call by Reference: No ( called with pass by value option)
WMARC_WERKS - Plant
Data type: MARC-WERKSOptional: No
Call by Reference: No ( called with pass by value option)
WMARC_STLAL - Alternative BOM
Data type: MARC-STLALOptional: No
Call by Reference: No ( called with pass by value option)
WMARC_STLAN - BOM Usage
Data type: MARC-STLANOptional: No
Call by Reference: No ( called with pass by value option)
WMARC_PLNNR - Key for Task List Group
Data type: MARC-PLNNROptional: No
Call by Reference: No ( called with pass by value option)
WMARC_APLAL - Group Counter
Data type: MARC-APLALOptional: No
Call by Reference: No ( called with pass by value option)
WMARC_PLNTY - Task List Type
Data type: MARC-PLNTYOptional: No
Call by Reference: No ( called with pass by value option)
WRMMG1_MTART - Material Type
Data type: RMMG1-MTARTOptional: No
Call by Reference: No ( called with pass by value option)
EXPORTING Parameters details for MARC_SOBSK
WMARC_SOBSK - Special Procurement Type for Costing
Data type: MARC-SOBSKOptional: No
Call by Reference: No ( called with pass by value option)
Copy and paste ABAP code example for MARC_SOBSK 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_wmarc_sobsk | TYPE MARC-SOBSK, " | |||
| lv_wmarc_sobsk | TYPE MARC-SOBSK, " | |||
| lv_p_message | TYPE RMMG08_012-MSGTYP, " SPACE | |||
| lv_wmarc_sobsl | TYPE MARC-SOBSL, " | |||
| lv_wmarc_werks | TYPE MARC-WERKS, " | |||
| lv_wmarc_stlal | TYPE MARC-STLAL, " | |||
| lv_wmarc_stlan | TYPE MARC-STLAN, " | |||
| lv_wmarc_plnnr | TYPE MARC-PLNNR, " | |||
| lv_wmarc_aplal | TYPE MARC-APLAL, " | |||
| lv_wmarc_plnty | TYPE MARC-PLNTY, " | |||
| lv_wrmmg1_mtart | TYPE RMMG1-MTART. " |
|   CALL FUNCTION 'MARC_SOBSK' "NOTRANSL: Prf. Sonderbeschaffungsschl. für die Kalkulation |
| EXPORTING | ||
| WMARC_SOBSK | = lv_wmarc_sobsk | |
| P_MESSAGE | = lv_p_message | |
| WMARC_SOBSL | = lv_wmarc_sobsl | |
| WMARC_WERKS | = lv_wmarc_werks | |
| WMARC_STLAL | = lv_wmarc_stlal | |
| WMARC_STLAN | = lv_wmarc_stlan | |
| WMARC_PLNNR | = lv_wmarc_plnnr | |
| WMARC_APLAL | = lv_wmarc_aplal | |
| WMARC_PLNTY | = lv_wmarc_plnty | |
| WRMMG1_MTART | = lv_wrmmg1_mtart | |
| IMPORTING | ||
| WMARC_SOBSK | = lv_wmarc_sobsk | |
| . " MARC_SOBSK | ||
ABAP code using 7.40 inline data declarations to call FM MARC_SOBSK
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 SOBSK FROM MARC INTO @DATA(ld_wmarc_sobsk). | ||||
| "SELECT single SOBSK FROM MARC INTO @DATA(ld_wmarc_sobsk). | ||||
| "SELECT single MSGTYP FROM RMMG08_012 INTO @DATA(ld_p_message). | ||||
| DATA(ld_p_message) | = ' '. | |||
| "SELECT single SOBSL FROM MARC INTO @DATA(ld_wmarc_sobsl). | ||||
| "SELECT single WERKS FROM MARC INTO @DATA(ld_wmarc_werks). | ||||
| "SELECT single STLAL FROM MARC INTO @DATA(ld_wmarc_stlal). | ||||
| "SELECT single STLAN FROM MARC INTO @DATA(ld_wmarc_stlan). | ||||
| "SELECT single PLNNR FROM MARC INTO @DATA(ld_wmarc_plnnr). | ||||
| "SELECT single APLAL FROM MARC INTO @DATA(ld_wmarc_aplal). | ||||
| "SELECT single PLNTY FROM MARC INTO @DATA(ld_wmarc_plnty). | ||||
| "SELECT single MTART FROM RMMG1 INTO @DATA(ld_wrmmg1_mtart). | ||||
Search for further information about these or an SAP related objects