0% found this document useful (0 votes)
15 views

How-To Using Data Replication Framework for Material V3.1

This document provides a comprehensive guide on using the Data Replication Framework (DRF) for material management in SAP Master Data Governance (MDG) and SAP S/4HANA. It covers prerequisites, business scenarios, troubleshooting, and detailed instructions for setting up and customizing DRF for efficient data replication. The guide includes updates on various versions and specific SAP notes relevant to DRF implementation and operation.

Uploaded by

sujaymeshram89
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
15 views

How-To Using Data Replication Framework for Material V3.1

This document provides a comprehensive guide on using the Data Replication Framework (DRF) for material management in SAP Master Data Governance (MDG) and SAP S/4HANA. It covers prerequisites, business scenarios, troubleshooting, and detailed instructions for setting up and customizing DRF for efficient data replication. The guide includes updates on various versions and specific SAP notes relevant to DRF implementation and operation.

Uploaded by

sujaymeshram89
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 14

PUBLIC

How To: Using Data Replication Framework for


Material

Applicable Releases:
From EHP6 FOR SAP ERP 6.0 and from SAP S/4HANA 1511

Version 3.1
September 2022
Document History

Document Version Description

1.0 First official release of this guide


1.1 Additional SAP notes and hints
1.2 Background information for using DRF for Materials
1.3 Update for RBWF
1.4 Updates to chapter 3.5 Key Mapping (including ALE Audit), new chapter
3.6
1.5 Updates to chapter 3.3 IDoc Reduction
1.6 Small corrections
1.7 Updates to 3.1 and new chapter 3.9
1.8 Updates for MDG 9.0
1.9 Validity update
2.0 SAP note 2268203
3.0 Deletion of chapter 5
3.1 Small updates, new chapter 3.4 Change Pointer (September 2022)
1. BUSINESS SCENARIO ....................................................................................................................................................... 4
2. PREREQUISITES............................................................................................................................................................... 5
3. BACKGROUND INFORMATION/TROUBLESHOOTING ON DRF FOR MATERIAL .................................................................... 6
3.1. RESTRICTIONS ............................................................................................................................................................................. 6
3.2. DRF SET UP, CUSTOMIZING, ONLINE HELP, SAP BEST PRACTICES EXPLORER ......................................................................................... 6
3.3. WEB DYNPRO APPLICATIONS......................................................................................................................................................... 7
3.4. CHANGE POINTER........................................................................................................................................................................ 7
3.5. IDOC REDUCTION ........................................................................................................................................................................ 7
3.6. REPLICATION OF DELETION ............................................................................................................................................................ 8
3.7. KEY MAPPING (INCLUDING ALE AUDIT) .......................................................................................................................................... 8
3.7.1. Key Mapping................................................................................................................................................................... 8
3.7.2. How to Customize ALE Audit .......................................................................................................................................... 9
3.7.3. ALE Audit and Classification IDoc’s ................................................................................................................................ 9
3.8. VALUE MAPPING......................................................................................................................................................................... 9
3.9. FILTER CRITERIA ........................................................................................................................................................................ 10
3.10. CHANGE OF DRF CHANGE POINTER GENERATION......................................................................................................................... 10
4. STEP-BY-STEP EXPLANATION FOR IMMEDIATE REPLICATION WITH MDG 9.0 AND SAP S/4HANA 1610 ............................. 12
5. RELATED CONTENT ....................................................................................................................................................... 13
5.1. FURTHER READING .................................................................................................................................................................... 13
5.2. SAP NOTES .............................................................................................................................................................................. 13

3
1. BUSINESS SCENARIO
SAP Master Data Governance for Material (MDG-M) provides business processes to find, create, change, and mark
material master data for deletion. It supports the governance of material master data on a central hub and the
distribution of material master data to connected operational and business intelligence systems.
The processes are workflow-driven and can include several approval and revision phases, including collaboration
between all users participating in master data maintenance.

The data replication framework (DRF) can be used to replicate data from the Master Data Governance (MDG) hub to
target systems.

You can replicate master data changes carried out centrally either manually or automatically in the background using
the data replication framework (DRF). Filters allow you to configure replication settings. You can replicate data
between the Master Data Governance hub and operational systems by means of SOAP services, IDoc’s, or file
download functions.

This guide provides background information about the data replication framework (DRF) valid for the domain material.

The guide also describes how to set up the system to enable immediate distribution of changes in the material master
during activation of the material. With MDG 9.0 and SAP S/4HANA 1610 it is configurable, if you would like to distribute
immediately or using change pointer.

4
2. PREREQUISITES

Makes sure that the following SAP Notes are implemented in the system if required:

Note Number Note Description


1910800 Error in replication using different replication models
1933608 Error in filtering objects while replication with DRF based Web UI
1934302
Segment filters do not get applied from DRFF when doing DRF based replication for Material
1935559 Issue in replication of material to multiple business system with different replication models
1947942 When performing DRF replication, MDG change pointer gets reset for materials which are
not indexed in ESH
1952654 Materials which gets delayed in indexing in enterprise search are not getting filtered for DRF
replication
2080421 DRF: Reduced IDoc message types cannot be sent
2084728 Reduced IDoc message types for MDG implementations
2093396 Reduced Message Type
2245651 Distribution of valuation data with different material ledger settings
2290691 Error during activation of material changes without direct distribution
2302817 Incomplete change information when you send material masters
2318497 Too many change pointers are created
2302809 QMAT not in UPDATE TASK
2288694 Context of current Change Request in DRF
2281192 MDG_BS_CLF_KEY_OBJKEY: Switch OBJKEY and KLART
2245651 Distribution of valuation data with different material ledger settings
2268203 Not possible to Update / Transfer MRP Area when using Message Type MATMAS
2482353 Call Material DRF Outbound without MDG data
2733860 MDG-DRF: Value Mapping on Custom Fields for Material
2977375 MDG-DRF: ABAP.PRX_PROTO_NOT_SUPPORTED Proxy error
3213158 Replication issue: IDOC is sent with old data
2700769 Enabling Automated Replication of Materials in S/4HANA

5
3. BACKGROUND INFORMATION/TROUBLESHOOTING ON DRF FOR MATERIAL

3.1. Restrictions
This guide is valid for an MDG-M system. This means that in Customizing under MDGIMG > Central Governance for
Material > Activate Business Transaction Events, the Application Active checkbox is selected for the MDGM
application. Without MDG the application LO-MD is set and DRF outbound implementations 194_2 (MATMAS IDocs)
or 194_3 (Product SOAP Services) are used. For more information, see SAP Note 2700769. All information in this guide
refers to an MDG-M system.

The DRF material outbound implementation I_MAT supports only ALE message types MATMAS (with
PRODVERSION) and CLFMAS.

With MDG 9.0 and outbound implementation I_MAT_V2 also ALE message types for quality inspection setup
(MATQM), change number and revision level (ECMREV) and documents (DOLMAS) are supported.

If you want to replicate change states/revision levels using IDoc ECMREV, you must also activate the ALE change
pointers using SALE -> IDoc Interface / Application Link Enabling (ALE) -> Modeling and Implementing Business
Processes-> Master Data Distribution-> Activate Change Pointers for Message Types (transaction BD50).

The DRF material outbound implementations do not support ALE message DOCMAS. For distribution of DOCMAS you
can use the standard ALE distribution.

ALE and DRF distribution for MRP Areas is not possible as no IDoc exists for distribution of MRP Areas (MDMA). See
also SAP Note 2268203: Not possible to Update / Transfer MRP Area when using Message Type MATMAS.

Only in S/4HANA it is also possible to use outbound implementation 194_3 for replication via services.
https://help.sap.com/viewer/bc6b9325fedd4344a84412b2195064fa/latest/en-
US/f758dc3b2f444f3fb6c6cabc8ebd1689.html

Flex entities are not supported by the DRF material outbound implementation.

3.2. DRF Set Up, Customizing, Online Help, SAP Best Practices Explorer
For more information, see the section Set Up Data Replication Using ALE with DRF in Configuring Master Data
Governance for Material topic Set Up Data Replication
https://help.sap.com/viewer/6d52de87aa0d4fb6a90924720a5b0549/latest/en-
US/64a5cb5285135721e10000000a423f68.html as well as the Data Replication topic in Working with MDG, Central
Governance https://help.sap.com/viewer/6d52de87aa0d4fb6a90924720a5b0549/latest/en-
US/104bf4bff9c54d7796d266605a4111fd.html.

Note: Don’t forget to run transaction MDGIMG and navigate to Central Governance for Material Activate Business
Transaction Events and select the Application Active checkbox for the MDGM Application Indicator to enable MDG
Material with DRF. For more information, see SAP Note 2700769.

For more information about the data replication framework in SAP S/4HANA, see the Data Replication Framework
topic https://help.sap.com/viewer/8308e6d301d54584a33cd04a9861bc52/latest/en-
US/88e3f5577c84bc12e10000000a4450e5.html.

For more information about the integration of SAP S/4HANA Cloud to SAP Master Data Governance, see SAP Best
Practices Explorer https://rapid.sap.com/bp/#/scopeitems/1RO.

6
3.3. Web Dynpro Applications
Web Dynpro applications can be found here on the material governance homepage:

Or you can use transaction DRFOUT. For scheduled distribution with a background job you should use a variant of
transaction DRFOUT.

3.4. Change Pointer


DRF change pointer are written because of the entries in table TBE11 (Application Active checkbox is selected for the
MDGM application) and TBE31 (function modules MDG_BS_MAT_DRF_CP and MDG_BS_CLF_DRF_CP for MDGM
application).

You can check the change pointer with transaction SE16n and table MDGD_CP to get the change pointer ID. Then
check table MDGD_CP_REP_STAT, that the status is now CR. There you can see that change pointer is written for
the business systems ID’s.

3.5. IDoc Reduction


Scenario:
You have defined a reduced IDoc type, which creates a new message type. You have also registered it for a target
system, but DRF does not create an IDoc.

Solution:
Implement the following SAP Notes:
• SAP Note 2080421: DRF: Reduced IDoc message types cannot be sent
• SAP Note 2084728: Reduced IDoc message types for MDG implementations
• SAP Note 2093396: Reduced Message Type

Workaround:
If you can’t implement these SAP Notes, you can use this as a workaround.

The message type MATMAS is hard coded in method SEND_MATMAS_IDOC of class CL_MDG_MAT_IDOC_DRF.
This class is used in the outbound implementation I_MAT for DRF.

7
Search for the usage IF_MDG_MAT_DRF_CONSTANTS=>GC_MATMAS. You must replace the hard-coded message
type using an overwrite exit on this method, or by creating your own outbound implementation (inheriting from class
CL_MDG_MAT_IDOC_DRF).

3.6. Replication of Deletion


Scenario:
You have replicated a material with several descriptions and long texts. You then delete some descriptions/long texts
(or any other segment where deletion is possible) and replicate the material again using IDoc and DRF. The deletions
do not reach the target system.

Root cause:
DRF for material does not support message function ‘003’ (deletion). DRF for material always sends the full material.
ALE/DRF filters are of course considered.

Solution options:
Using only ALE:
Sending a segment deletion is supported in standard ALE (transaction BD21). This option doesn’t need additional
coding.

Using DRF or ALE:


This option needs additional coding in the target systems. If it is possible to determine which data gets deleted in the
target system, you can also implement the IDoc inbound BAdI IDOC_DATA_MAPPER in the target system. In this
BAdI, set the segment’s message function (MSGFN) to ‘003’ (deletion). This enables the IDoc inbound (usually
function module IDOC_INPUT_MATMAS01) to delete the data.
This above case works for segments that are solely maintained on the hub (no data added in the target system).
If one such segment exists in the target system’s database but not in the IDoc, then this could be considered an
indication that this segment must be deleted. These rules and the implementation are project specific so no example
coding is provided.

3.7. Key Mapping (Including ALE Audit)


If possible, harmonized material numbers in your landscape are considered best practice. This would avoid key
mapping completely, but is not always possible (legacy systems with non-harmonized material numbers …). In this
case, MDGM also supports key mapping.

3.7.1. Key Mapping


For key mapping of material numbers, IDoc types MATMAS01..5 and CLFMAS01..2 use the ‘Object Identifier Type
Code’ number 20 “Material ID (internal format) (ERP)”. MDG-M supports the following three options, based on the
settings in “Define Technical Settings for Business Systems”
1. “Harmonized IDs”: Key mapping not considered
2. “Key Mapping” and (“Update KM via ALE audit” unchecked or BD10 outbound):
o Key mapping needed for material
o DRF/ALE outbound fails if key mapping is missing
3. DRF only: “Key Mapping” and “Update KM” (via ALE audit) checked:
o Key mapping considered if available
o Otherwise, the hub sends its material number; client can
▪ Either accept it and confirm via ALE audit
▪ Or provide new, internally assigned material number;
this material number gets returned via ALE Audit and the key mapping gets updated on Hub;
for IDoc inbound with internal numbering, check http://scn.sap.com/thread/1954090

8
3.7.2. How to Customize ALE Audit
You can configure your client and hub systems so that your client systems send confirmation of replicated materials
back to the MDG hub. The technology that is used for this is called ALE auditing. The customizing for ALE audit is
described in the section Customizing for ALE Audit (Optional) in Adapting Master Data Governance for Material → Key
Mapping https://help.sap.com/viewer/db97296fe85d45f9b846e8cd2a580fbd/MDG92.latest/en-US

3.7.3. ALE Audit and Classification IDoc’s

Scenario:
Option 3 (ALE audit) is used to replicate material with classification, key mapping required, update via ALE Audit active
(key created in target system)

Challenge:
The CLFMAS IDoc’s must not be sent until ALE audit has returned the material number of the target system and
updated the key mapping. To ensure this, the classification outbound will fail with an error message in the ALE
replication log (BD87) if no key mapping was found. Thus, the DRF change pointers will be set to processed but the
CLFMAS IDoc will not be sent but instead get an error status.
Note that no message is written into the DRF log, only the ALE log (as it was there where the replication failed).
After the ALE audit has updated the key mapping, the CLFMAS IDoc’s need to be replicated again. Unfortunately, this
replication can’t be automated from the ALE audit.

Solution:
Prerequisite is SAP Note 2030807.

Type Solution
Initial Load Retrigger replication for materials whose CLFMAS IDoc’s have failed – check BD87. No work list
available.
Delta Delta is driven by change pointers → new change pointers created for failed classification IDoc’s
→ for next periodic replication, material including CLFMAS will be sent again
Manual Restart replication for materials whose CLFMAS IDoc’s have failed – check BD87. No work list
available.
CR Custom coding: WAIT task until DRF replication status indicates that the ALE Audit was finished,
Activation then restart replication
Note that the restart sends CLFMAS IDoc as well as the corresponding MATMAS IDoc, which is somewhat redundant.

3.8. Value Mapping


For value mapping see How To Guide Using Data Import Framework (DIF), chapter Value Mapping.
The customizing is valid for inbound and outbound.

9
3.9. Filter Criteria
Filter Object - Defines the selection criteria used to determine the data objects which should be replicated. It combines
one or more filters. Maintenance of the selection criteria is done by the master data steward.

Filter - Carries out the comparison of a given set of objects against the maintained filter criteria. It returns the list of
objects that match the filter criteria. To apply filters sequentially on the same object list, they can be combined in Filter
Objects. Filter types available: Explicit (simple and complex) and implicit. Segment Filters are special filters that
generally do not limit the number of objects but the amount of data in the object itself.

Explicit filters are configured explicitly by the customer


• Simple filters are defined per attributes on a single ERP or S/4HANA entity root table - e.g. fields
MATNR, MATKL and MTART of table MARA. The evaluation of simple filters is generic in the way that it
can be easily enhanced just by adding another attribute to the filter using append technology (no code
change necessary).
• Complex filters are not directly related to the ERP or S/4HANA entity root table but need to get
evaluated by certain function modules or methods like selected nodes of the article hierarchy or
merchandise category hierarchy. The semantically interpretation of complex filters is coded using the
corresponding APIs. To enhance complex filters code changes are necessary.
Implicit filters are offered by the system
• In addition to simple and complex filter the system offers implicit filters (reusable APIs).
They are executed by the system and can only be switched on or off using the configuration on the
Replication Model/Outbound Implementation level.
• Examples are checks of certain material/store combinations due to listing conditions or selling periods

Segment filters are used to exclude parts (“segments”) of the Business Object from replication.

The delivered outbound implementation I_MAT has the following filter criteria’s, which you can find in the MDG
customizing: General Settings->Data Replication->Enhance Default Settings for Outbound Implementations->Define
Outbound Implementations.

• Main filter in outbound implementation with Filter Object MDG_BS_MAT

• Segment filters F_MAT1 bis F_MAT6

If these filters are not sufficient you can create your own outbound implementation with own filters. Filters are defined in
the MDG customizing: General Settings->Data Replication->Enhance Default Settings for Outbound Implementations->
Define Filter Objects.

3.10. Change of DRF change pointer generation


Scenario:
You want to influence the DRF change pointers.

Solution:
The DRF change pointer creation is triggered by a BTE (Business Transaction Event) as stored in table TBE31. To
prevent this creation, you should exchange/remove the two entries for MDG_BS_MAT_DRF_CP for BTE 00001250
and MDG_BS_CLF_DRF_CP for BTE 00004002. This is a modification.

In addition, different change pointer should be written. This could be achieved by:
• Alternative 1: Copy function module MDG_BS_MAT_DRF_CP and change the coding according to your
requirements. Then exchange the function module in table TBE31.

• Alternative 2: Use ALE-BAdI BDCP_BEFORE_WRITE. There you can create DRF change pointers if ALE
change pointers are created for the ALE-Message type. Prerequisite is the assignment of ALE-Message Type

10
to the Business Object.

11
4. STEP-BY-STEP EXPLANATION FOR IMMEDIATE REPLICATION WITH MDG 9.0 AND SAP S/4HANA 1610

From MDG 9.0 and SAP S/4HANA 1610 it is possible to configure pooled or direct replication.

See configuration Guide MDG-M Set Up Data Replication


https://help.sap.com/viewer/6d52de87aa0d4fb6a90924720a5b0549/latest/en-
US/64a5cb5285135721e10000000a423f68.html

12
5. RELATED CONTENT
5.1. Further Reading
Information on SAP MDG on SAP S/4HANA
• Exchange knowledge: SAP Community | Q&A | Blog
• Try SAP Master Data Governance on S/4HANA for free: Trial Version
• Learn more: Latest Release | Webinars | Help Portal | How-to Information | Key Presentations

SAP Roadmap Explorer


• Please see the roadmap for SAP Master Data Governance

Related Information
• Learn more: Floorplan Manager for Web Dynpro ABAP | How to Adapt FPM | FPM Blog | How-to Information |
Service Mapping Tool |

5.2. SAP Notes


In addition to the detailed explanations written in this document, please see the following SAP Notes for further
important information.

Note Number Note Description


1806108 Functional restrictions in MDG-M in MDG7 (incl. SP02)
2129261 Functional restrictions in MDG-M in MDG8
2284745 Functional Restrictions in MDG for Material with SAP Master Data Governance 9.0

2461516 Functional Restrictions in MDG for Material with SAP Master Data Governance 9.1
Functional Restrictions in MDG for Material in SAP Master Data Governance 9.2 and on
2656693 SAP S/4HANA 1809
2816571 Functional Restrictions in MDG for Material on SAP S/4HANA 1909

2948873 Functional Restrictions in MDG for Material on SAP S/4HANA 2020

2479869 Usage of Lean Classification with SAP Master Data Governance

3070012 Functional Restrictions in MDG for Material on SAP S/4HANA 2021

3219945 Functional Restrictions in MDG for Material on SAP S/4HANA 2022

3194967 MDG Customer Connection 2021 for S/4HANA 2022


3043582 MDG Customer Connection 2020

13
www.sap.com/contactsap

© 2022 SAP SE or an SAP affiliate company. All rights reserved.


No part of this publication may be reproduced or transmitted in any form or for any purpose without the express permission of SAP SE or an SAP affiliate company.

The information contained herein may be changed without prior notice. Some software products marketed by SAP SE and its distributors contain proprietary software components of other software vendors. National
product specifications may vary.

These materials are provided by SAP SE or an SAP affiliate company for informational purposes only, without representation or warranty of any kind, and SAP or its affiliated companies shall not be liable for errors or
omissions with respect to the materials. The only warranties for SAP or SAP affiliate company products and services are those that are set forth in the express warranty statements accompanying such products and
services, if any. Nothing herein should be construed as constituting an additional warranty.

In particular, SAP SE or its affiliated companies have no obligation to pursue any course of business outlined in this document or any related presentation, or to develop or release any functionality mentioned therein.
This document, or any related presentation, and SAP SE’s or its affiliated companies’ strategy and possible future developments, products, and/or platform directions and functionality are all subject to change and may
be changed by SAP SE or its affiliated companies at any time for any reason without notice. The information in this document is not a commitment, promise, or legal obligation to deliver any material, code, or
functionality. All forward-looking statements are subject to various risks and uncertainties that could cause actual results to differ materially from expectations. Readers are cautioned not to place undue reliance on
these forward-looking statements, and they should not be relied upon in making purchasing decisions.

SAP and other SAP products and services mentioned herein as well as their respective logos are trademarks or registered trademarks of SAP SE (or an SAP affiliate company) in Germany and other countries. All
other product and service names mentioned are the trademarks of their respective companies. See www.sap.com/trademark for additional trademark information and notices.

You might also like