SAP MATERIAL_REFERENCE_RT_UPDATE_N Function Module for NOTRANSL: Neuanlage fehlender Werkssätze beim Anlegen eines Einzelmaterial









MATERIAL_REFERENCE_RT_UPDATE_N is a standard material reference rt update n 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: Neuanlage fehlender Werkssätze beim Anlegen eines Einzelmaterial 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 material reference rt update n FM, simply by entering the name MATERIAL_REFERENCE_RT_UPDATE_N into the relevant SAP transaction such as SE37 or SE38.

Function Group: MGWL
Program Name: SAPLMGWL
Main Program: SAPLMGWL
Appliation area: M
Release date: N/A
Mode(Normal, Remote etc): Normal Function Module
Update:



Function MATERIAL_REFERENCE_RT_UPDATE_N 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 'MATERIAL_REFERENCE_RT_UPDATE_N'"NOTRANSL: Neuanlage fehlender Werkssätze beim Anlegen eines Einzelmaterial
EXPORTING
MATNR = "Material Number
SATNR = "Cross-Plant Configurable Material
MARA_AKT = "General Material Data
MAW1_AKT = "Material Master: Default Fields and Special Retail Fields
* KZRFB = ' ' "Indicator: reset buffer for Material_Pre_Fetch
* FLG_UEBERNAHME = ' ' "Propose Field Content from the Reference
* P_CALL_MODE2 = ' ' "3-Byte field

TABLES
TWERKSTAB = "Assignment of Plants to Materials
T_MABW_NEW = "Management of Differently Maintained Material Data in Retail
MARC_INS = "Plant Data for Material
MARD_INS = "Storage Location Data for Material
MBEW_INS = "Material Valuation
MPGD_INS = "Change Document Structure for Material Master/Product Group
MFHM_INS = "Production Resource Tool (PRT) Fields in the Material Master
MPOP_INS = "Forecast Parameters
MLGN_INS = "Material Data for Each Warehouse Number
MLGT_INS = "Material Data for Each Storage Type

EXCEPTIONS
NO_REF_WERKS_DATA = 1 NO_REF_BWKEY_DATA = 2
.



IMPORTING Parameters details for MATERIAL_REFERENCE_RT_UPDATE_N

MATNR - Material Number

Data type: MARA-MATNR
Optional: No
Call by Reference: No ( called with pass by value option)

SATNR - Cross-Plant Configurable Material

Data type: MARA-SATNR
Optional: No
Call by Reference: No ( called with pass by value option)

MARA_AKT - General Material Data

Data type: MARA
Optional: No
Call by Reference: No ( called with pass by value option)

MAW1_AKT - Material Master: Default Fields and Special Retail Fields

Data type: MAW1
Optional: No
Call by Reference: No ( called with pass by value option)

KZRFB - Indicator: reset buffer for Material_Pre_Fetch

Data type: MTCOM-KZRFB
Default: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)

FLG_UEBERNAHME - Propose Field Content from the Reference

Data type: T130F-KZREF
Default: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)

P_CALL_MODE2 - 3-Byte field

Data type: RMMG2-CALL_MODE2
Default: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)

TABLES Parameters details for MATERIAL_REFERENCE_RT_UPDATE_N

TWERKSTAB - Assignment of Plants to Materials

Data type: WERKSTAB
Optional: No
Call by Reference: No ( called with pass by value option)

T_MABW_NEW - Management of Differently Maintained Material Data in Retail

Data type: MABW
Optional: No
Call by Reference: No ( called with pass by value option)

MARC_INS - Plant Data for Material

Data type: MARC
Optional: No
Call by Reference: No ( called with pass by value option)

MARD_INS - Storage Location Data for Material

Data type: MARD
Optional: No
Call by Reference: No ( called with pass by value option)

MBEW_INS - Material Valuation

Data type: MBEW
Optional: No
Call by Reference: No ( called with pass by value option)

MPGD_INS - Change Document Structure for Material Master/Product Group

Data type: MPGD
Optional: No
Call by Reference: No ( called with pass by value option)

MFHM_INS - Production Resource Tool (PRT) Fields in the Material Master

Data type: MFHM
Optional: No
Call by Reference: No ( called with pass by value option)

MPOP_INS - Forecast Parameters

Data type: MPOP
Optional: No
Call by Reference: No ( called with pass by value option)

MLGN_INS - Material Data for Each Warehouse Number

Data type: MLGN
Optional: No
Call by Reference: No ( called with pass by value option)

MLGT_INS - Material Data for Each Storage Type

Data type: MLGT
Optional: No
Call by Reference: No ( called with pass by value option)

EXCEPTIONS details

NO_REF_WERKS_DATA -

Data type:
Optional: No
Call by Reference: No ( called with pass by value option)

NO_REF_BWKEY_DATA -

Data type:
Optional: No
Call by Reference: No ( called with pass by value option)

Copy and paste ABAP code example for MATERIAL_REFERENCE_RT_UPDATE_N 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_matnr  TYPE MARA-MATNR, "   
lt_twerkstab  TYPE STANDARD TABLE OF WERKSTAB, "   
lv_no_ref_werks_data  TYPE WERKSTAB, "   
lt_t_mabw_new  TYPE STANDARD TABLE OF MABW, "   
lv_satnr  TYPE MARA-SATNR, "   
lt_marc_ins  TYPE STANDARD TABLE OF MARC, "   
lv_no_ref_bwkey_data  TYPE MARC, "   
lv_mara_akt  TYPE MARA, "   
lt_mard_ins  TYPE STANDARD TABLE OF MARD, "   
lv_maw1_akt  TYPE MAW1, "   
lt_mbew_ins  TYPE STANDARD TABLE OF MBEW, "   
lv_kzrfb  TYPE MTCOM-KZRFB, "   SPACE
lt_mpgd_ins  TYPE STANDARD TABLE OF MPGD, "   
lt_mfhm_ins  TYPE STANDARD TABLE OF MFHM, "   
lv_flg_uebernahme  TYPE T130F-KZREF, "   SPACE
lt_mpop_ins  TYPE STANDARD TABLE OF MPOP, "   
lv_p_call_mode2  TYPE RMMG2-CALL_MODE2, "   SPACE
lt_mlgn_ins  TYPE STANDARD TABLE OF MLGN, "   
lt_mlgt_ins  TYPE STANDARD TABLE OF MLGT. "   

  CALL FUNCTION 'MATERIAL_REFERENCE_RT_UPDATE_N'  "NOTRANSL: Neuanlage fehlender Werkssätze beim Anlegen eines Einzelmaterial
    EXPORTING
         MATNR = lv_matnr
         SATNR = lv_satnr
         MARA_AKT = lv_mara_akt
         MAW1_AKT = lv_maw1_akt
         KZRFB = lv_kzrfb
         FLG_UEBERNAHME = lv_flg_uebernahme
         P_CALL_MODE2 = lv_p_call_mode2
    TABLES
         TWERKSTAB = lt_twerkstab
         T_MABW_NEW = lt_t_mabw_new
         MARC_INS = lt_marc_ins
         MARD_INS = lt_mard_ins
         MBEW_INS = lt_mbew_ins
         MPGD_INS = lt_mpgd_ins
         MFHM_INS = lt_mfhm_ins
         MPOP_INS = lt_mpop_ins
         MLGN_INS = lt_mlgn_ins
         MLGT_INS = lt_mlgt_ins
    EXCEPTIONS
        NO_REF_WERKS_DATA = 1
        NO_REF_BWKEY_DATA = 2
. " MATERIAL_REFERENCE_RT_UPDATE_N




ABAP code using 7.40 inline data declarations to call FM MATERIAL_REFERENCE_RT_UPDATE_N

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 MATNR FROM MARA INTO @DATA(ld_matnr).
 
 
 
 
"SELECT single SATNR FROM MARA INTO @DATA(ld_satnr).
 
 
 
 
 
 
 
"SELECT single KZRFB FROM MTCOM INTO @DATA(ld_kzrfb).
DATA(ld_kzrfb) = ' '.
 
 
 
"SELECT single KZREF FROM T130F INTO @DATA(ld_flg_uebernahme).
DATA(ld_flg_uebernahme) = ' '.
 
 
"SELECT single CALL_MODE2 FROM RMMG2 INTO @DATA(ld_p_call_mode2).
DATA(ld_p_call_mode2) = ' '.
 
 
 


Search for further information about these or an SAP related objects



Comments on this SAP object

What made you want to lookup this SAP object? Please tell us what you were looking for and anything you would like to be included on this page!