SAP MCB_MCMSEG_FILL Function Module for NOTRANSL: Füllt Kommunikationsstrukturen für Bestandscontrolling
MCB_MCMSEG_FILL is a standard mcb mcmseg fill 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: Füllt Kommunikationsstrukturen für Bestandscontrolling 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 mcb mcmseg fill FM, simply by entering the name MCB_MCMSEG_FILL into the relevant SAP transaction such as SE37 or SE38.
Function Group: MCB1
Program Name: SAPLMCB1
Main Program: SAPLMCB1
Appliation area: M
Release date: N/A
Mode(Normal, Remote etc): Normal Function Module
Update:

Function MCB_MCMSEG_FILL 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 'MCB_MCMSEG_FILL'"NOTRANSL: Füllt Kommunikationsstrukturen für Bestandscontrolling.
EXPORTING
I_MSEG = "Document Segment: Material
* I_ZEITP = 'BF' "Event for which updating should take place
* I_MCBEST = "Stock Fields and Material Master Information
* I_VM07M = "Fields: Update Control of Module Pool SAPMM07M
* I_DM07M = "Dialog Control Fields for Module Pool SAPMM07M
* I_MODUS = "Mode of Info Structure Update in LIS
IMPORTING
E_MCMSEG_L = "Document Segment: Material
E_MCMSEG_K = "Document Segment: Material
E_MCBEST = "Stock Fields and Material Master Information
TABLES
* YT156 = "Movement Type
* YT156B = "Movement Types: Screen Selection
* YT156S = "View
* YT156M = "Posting String: Quantity
* YT156C = "Stock Types and Their Values
* YT001W = "Plants/Subsidiaries
* YT134M = "Control of Qty/Value Update
* YMKPF = "Header: Material Document
* YMSEG = "Document Segment: Material
Customer Function user exits
Below is a list of CUSTOMER FUNCTION exit user exits that are available within this program and maybe relevant for this FM.EXIT_SAPLMCB1_001 User Exit for Inventory Controlling
IMPORTING Parameters details for MCB_MCMSEG_FILL
I_MSEG - Document Segment: Material
Data type: MSEGOptional: No
Call by Reference: No ( called with pass by value option)
I_ZEITP - Event for which updating should take place
Data type: MCCONTROL-ZEITPDefault: 'BF'
Optional: Yes
Call by Reference: No ( called with pass by value option)
I_MCBEST - Stock Fields and Material Master Information
Data type: MCBESTOptional: Yes
Call by Reference: No ( called with pass by value option)
I_VM07M - Fields: Update Control of Module Pool SAPMM07M
Data type: VM07MOptional: Yes
Call by Reference: No ( called with pass by value option)
I_DM07M - Dialog Control Fields for Module Pool SAPMM07M
Data type: DM07MOptional: Yes
Call by Reference: No ( called with pass by value option)
I_MODUS - Mode of Info Structure Update in LIS
Data type: MCCONTROL-MODUSOptional: Yes
Call by Reference: No ( called with pass by value option)
EXPORTING Parameters details for MCB_MCMSEG_FILL
E_MCMSEG_L - Document Segment: Material
Data type: MCMSEGOptional: No
Call by Reference: No ( called with pass by value option)
E_MCMSEG_K - Document Segment: Material
Data type: MCMSEGOptional: No
Call by Reference: No ( called with pass by value option)
E_MCBEST - Stock Fields and Material Master Information
Data type: MCBESTOptional: No
Call by Reference: No ( called with pass by value option)
TABLES Parameters details for MCB_MCMSEG_FILL
YT156 - Movement Type
Data type: T156Optional: Yes
Call by Reference: No ( called with pass by value option)
YT156B - Movement Types: Screen Selection
Data type: T156BOptional: Yes
Call by Reference: No ( called with pass by value option)
YT156S - View
Data type: V156SOptional: Yes
Call by Reference: No ( called with pass by value option)
YT156M - Posting String: Quantity
Data type: T156MOptional: Yes
Call by Reference: No ( called with pass by value option)
YT156C - Stock Types and Their Values
Data type: T156COptional: Yes
Call by Reference: No ( called with pass by value option)
YT001W - Plants/Subsidiaries
Data type: T001WOptional: Yes
Call by Reference: No ( called with pass by value option)
YT134M - Control of Qty/Value Update
Data type: T134MOptional: Yes
Call by Reference: No ( called with pass by value option)
YMKPF - Header: Material Document
Data type: MKPFOptional: Yes
Call by Reference: No ( called with pass by value option)
YMSEG - Document Segment: Material
Data type: MSEGOptional: Yes
Call by Reference: Yes
Copy and paste ABAP code example for MCB_MCMSEG_FILL 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: | ||||
| lt_yt156 | TYPE STANDARD TABLE OF T156, " | |||
| lv_i_mseg | TYPE MSEG, " | |||
| lv_e_mcmseg_l | TYPE MCMSEG, " | |||
| lt_yt156b | TYPE STANDARD TABLE OF T156B, " | |||
| lv_i_zeitp | TYPE MCCONTROL-ZEITP, " 'BF' | |||
| lv_e_mcmseg_k | TYPE MCMSEG, " | |||
| lt_yt156s | TYPE STANDARD TABLE OF V156S, " | |||
| lv_e_mcbest | TYPE MCBEST, " | |||
| lv_i_mcbest | TYPE MCBEST, " | |||
| lt_yt156m | TYPE STANDARD TABLE OF T156M, " | |||
| lv_i_vm07m | TYPE VM07M, " | |||
| lt_yt156c | TYPE STANDARD TABLE OF T156C, " | |||
| lv_i_dm07m | TYPE DM07M, " | |||
| lt_yt001w | TYPE STANDARD TABLE OF T001W, " | |||
| lv_i_modus | TYPE MCCONTROL-MODUS, " | |||
| lt_yt134m | TYPE STANDARD TABLE OF T134M, " | |||
| lt_ymkpf | TYPE STANDARD TABLE OF MKPF, " | |||
| lt_ymseg | TYPE STANDARD TABLE OF MSEG. " |
|   CALL FUNCTION 'MCB_MCMSEG_FILL' "NOTRANSL: Füllt Kommunikationsstrukturen für Bestandscontrolling |
| EXPORTING | ||
| I_MSEG | = lv_i_mseg | |
| I_ZEITP | = lv_i_zeitp | |
| I_MCBEST | = lv_i_mcbest | |
| I_VM07M | = lv_i_vm07m | |
| I_DM07M | = lv_i_dm07m | |
| I_MODUS | = lv_i_modus | |
| IMPORTING | ||
| E_MCMSEG_L | = lv_e_mcmseg_l | |
| E_MCMSEG_K | = lv_e_mcmseg_k | |
| E_MCBEST | = lv_e_mcbest | |
| TABLES | ||
| YT156 | = lt_yt156 | |
| YT156B | = lt_yt156b | |
| YT156S | = lt_yt156s | |
| YT156M | = lt_yt156m | |
| YT156C | = lt_yt156c | |
| YT001W | = lt_yt001w | |
| YT134M | = lt_yt134m | |
| YMKPF | = lt_ymkpf | |
| YMSEG | = lt_ymseg | |
| . " MCB_MCMSEG_FILL | ||
ABAP code using 7.40 inline data declarations to call FM MCB_MCMSEG_FILL
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 ZEITP FROM MCCONTROL INTO @DATA(ld_i_zeitp). | ||||
| DATA(ld_i_zeitp) | = 'BF'. | |||
| "SELECT single MODUS FROM MCCONTROL INTO @DATA(ld_i_modus). | ||||
Search for further information about these or an SAP related objects