Extend SAP Master Data Governance (MDG) -S / SAP Master Data Governance (MDG) -C Data Model by a New Field (Reuse Option)
PUBLIC
How-To: Extend MDG-S / MDG-C by a new
custom-defined field (reuse option)
Applicable Releases:
From EhP6 for SAP ERP 6.0 and from S/4HANA 1511
Version 4.0
December 2024
How-To: Extend MDG-S / MDG-C by a new
custom-defined field (reuse option)
Applicable Releases:
From EhP6 for SAP ERP 6.0 and from S/4HANA 1511
Version 4.0
December 2024
© 2024 SAP SE or an SAP affiliate company. All rights reserved. See Legal Notice on www.sap.com/legal-notice for use terms, disclaimers, disclosures, or restrictions related to this material.
2 / 65
Document History
Document Version Description
1.0 First official release of this guide (March 2012)
2.0 Layout (July 2020)
3.0 Additional information (August 2022)
4.0 Additional information (December 2024)
2 / 65
Document History
Document Version Description
1.0 First official release of this guide (March 2012)
2.0 Layout (July 2020)
3.0 Additional information (August 2022)
4.0 Additional information (December 2024)
© 2024 SAP SE or an SAP affiliate company. All rights reserved. See Legal Notice on www.sap.com/legal-notice for use terms, disclaimers, disclosures, or restrictions related to this material.
3 / 65
1. BUSINESS SCENARIO 4
1.1. DATA M ODEL 4
2. STEP BY STEP EXPLANATION 5
2.1. E XTENDED FIELD EXISTS IN BUSINESS P ARTNER O NLY 5
2.1.1. Extend the BUT000 Data Model 7
2.1.2. Extend the MDG Data Model 9
2.1.3. Generate Data Model-Specific Structures for MDG 11
2.1.4. Define SMT Mapping 13
2.1.5. Check Customizing 19
2.1.6. Define Field Properties for UI 20
2.1.7. Custom Handler Class 20
2.1.8. Define Field Mapping for SAP HANA-Based Search 21
2.1.9. Enhance Search UIBB 23
2.1.10. Adjust Staging Area of Linked Change Requests 25
2.1.11. Test Your Configuration 25
2.2. E XTENDED FIELD EXISTS IN VENDOR / CUSTOMER O NLY 27
2.2.1. Extend the MDG Data Model 28
2.2.2. Generate Data Model-Specific Structures for MDG 31
2.2.3. Define SMT Mapping 33
2.2.4. Test Your Configuration 39
2.3. E XTENDED FIELD EXISTS IN BUSINESS P ARTNER AND IN VENDOR / CUSTOMER 41
2.3.1. Extend LFA1 42
2.3.2. Implement Enhancement Spot CVI_CUSTOM_MAPPER 45
2.3.3. Test Your Configuration 47
2.4. USER I NTERFACE CONFIGURATION 48
2.4.1. Adaptation Options in Floorplan Manager 48
2.4.2. Adding a New Field to UI for Single Maintenance (BUT000 Extension Case) 49
2.4.3. Adding a New Field to the UI for Single Maintenance (Extended Field Exists in Vendor / Customer Only)
51
3. ADDITIONAL INFORMATION 54
3.1. FURTHER READING 54
3.1.1. Information on SAP MDG on SAP S/4HANA 54
3.1.2. SAP Roadmap Explorer 54
3.1.3. Related Information 54
3.2. SAP N OTES 54
4. APPENDIX 56
4.1. E XAMPLE CODING FOR CLASS ZCL_CUSTOM_BP_HANDLER 56
3 / 65
1. BUSINESS SCENARIO 4
1.1. DATA M ODEL 4
2. STEP BY STEP EXPLANATION 5
2.1. E XTENDED FIELD EXISTS IN BUSINESS P ARTNER O NLY 5
2.1.1. Extend the BUT000 Data Model 7
2.1.2. Extend the MDG Data Model 9
2.1.3. Generate Data Model-Specific Structures for MDG 11
2.1.4. Define SMT Mapping 13
2.1.5. Check Customizing 19
2.1.6. Define Field Properties for UI 20
2.1.7. Custom Handler Class 20
2.1.8. Define Field Mapping for SAP HANA-Based Search 21
2.1.9. Enhance Search UIBB 23
2.1.10. Adjust Staging Area of Linked Change Requests 25
2.1.11. Test Your Configuration 25
2.2. E XTENDED FIELD EXISTS IN VENDOR / CUSTOMER O NLY 27
2.2.1. Extend the MDG Data Model 28
2.2.2. Generate Data Model-Specific Structures for MDG 31
2.2.3. Define SMT Mapping 33
2.2.4. Test Your Configuration 39
2.3. E XTENDED FIELD EXISTS IN BUSINESS P ARTNER AND IN VENDOR / CUSTOMER 41
2.3.1. Extend LFA1 42
2.3.2. Implement Enhancement Spot CVI_CUSTOM_MAPPER 45
2.3.3. Test Your Configuration 47
2.4. USER I NTERFACE CONFIGURATION 48
2.4.1. Adaptation Options in Floorplan Manager 48
2.4.2. Adding a New Field to UI for Single Maintenance (BUT000 Extension Case) 49
2.4.3. Adding a New Field to the UI for Single Maintenance (Extended Field Exists in Vendor / Customer Only)
51
3. ADDITIONAL INFORMATION 54
3.1. FURTHER READING 54
3.1.1. Information on SAP MDG on SAP S/4HANA 54
3.1.2. SAP Roadmap Explorer 54
3.1.3. Related Information 54
3.2. SAP N OTES 54
4. APPENDIX 56
4.1. E XAMPLE CODING FOR CLASS ZCL_CUSTOM_BP_HANDLER 56
© 2024 SAP SE or an SAP affiliate company. All rights reserved. See Legal Notice on www.sap.com/legal-notice for use terms, disclaimers, disclosures, or restrictions related to this material.
4 / 65
1. BUSINESS SCENARIO
SAP Master Data Governance provides business processes to find, create, change, and mark master data
for deletion. It supports the governance of master data in a central hub and the distribution to connected
operational and business intelligence systems.
Domain-specific content (data models, user interfaces, workflows) is provided as part of the standard for
several application areas. It is a common requirement from customers to adapt the MDG data models to their
specific needs.
This How To Guide describes how to extend the data model BP by adding attributes that already exist as
database fields in the appropriate customer includes.
1.1. Data Model
In SAP Master Data Governance data can be stored in the staging area or in the active area. The staging
area temporarily stores the working version of master data that is undergoing change within a change
request process. The active area permanently stores active instances of master data after changes have
been approved by a change request process.
Extending the data model in SAP Master Data Governance with custom attributes involves changes to the
data structures in the active area and in the staging area. It also involves defining a mapping between these.
You can extend the data model BP by adding attributes that already exist as database fields in the
appropriate ERP tables. This method of extending the data model is called the MDG reuse option.
Your implementation of the reuse option depends on the ERP tables that store the master data after it is
activated. The following options are available:
• Extended field exists in Business Partner
• Extended field exists in Vendor / Customer
The new field is only extended as a database field in the customer include Ext. Interface:
Central Vendor Data / Data Fields (VMDS_EI_VMD_CENTRAL_DATA) for the vendor data
model as well as in either the customer include Ext. Interface: Central Vendor Data / X-
Fields (VMDS_EI_VMD_CENTRAL_DATA_XFLAG) for the vendor data model or in the
equivalent customer include for the customer data model.
• Extended Field Exists in Business Partner and in Vendor / Customer
The new field is extended as a database field in both the Business Partner and in customer
includes for vendor / customer.
Each of the sections in this document contains detailed step-by-step implementation instructions. Follow the
steps in the section that is appropriate for your scenario.
These cases are also shown in the figure below.
Note:
You can create new attributes in the customer namespace, for example, under ZZ* and YY*.
Add field
( reuse )
Field only in
Business Partner
Field only in
Vendor /
Customer
Field in both BP
and Vendor /
Customer
4 / 65
1. BUSINESS SCENARIO
SAP Master Data Governance provides business processes to find, create, change, and mark master data
for deletion. It supports the governance of master data in a central hub and the distribution to connected
operational and business intelligence systems.
Domain-specific content (data models, user interfaces, workflows) is provided as part of the standard for
several application areas. It is a common requirement from customers to adapt the MDG data models to their
specific needs.
This How To Guide describes how to extend the data model BP by adding attributes that already exist as
database fields in the appropriate customer includes.
1.1. Data Model
In SAP Master Data Governance data can be stored in the staging area or in the active area. The staging
area temporarily stores the working version of master data that is undergoing change within a change
request process. The active area permanently stores active instances of master data after changes have
been approved by a change request process.
Extending the data model in SAP Master Data Governance with custom attributes involves changes to the
data structures in the active area and in the staging area. It also involves defining a mapping between these.
You can extend the data model BP by adding attributes that already exist as database fields in the
appropriate ERP tables. This method of extending the data model is called the MDG reuse option.
Your implementation of the reuse option depends on the ERP tables that store the master data after it is
activated. The following options are available:
• Extended field exists in Business Partner
• Extended field exists in Vendor / Customer
The new field is only extended as a database field in the customer include Ext. Interface:
Central Vendor Data / Data Fields (VMDS_EI_VMD_CENTRAL_DATA) for the vendor data
model as well as in either the customer include Ext. Interface: Central Vendor Data / X-
Fields (VMDS_EI_VMD_CENTRAL_DATA_XFLAG) for the vendor data model or in the
equivalent customer include for the customer data model.
• Extended Field Exists in Business Partner and in Vendor / Customer
The new field is extended as a database field in both the Business Partner and in customer
includes for vendor / customer.
Each of the sections in this document contains detailed step-by-step implementation instructions. Follow the
steps in the section that is appropriate for your scenario.
These cases are also shown in the figure below.
Note:
You can create new attributes in the customer namespace, for example, under ZZ* and YY*.
Add field
( reuse )
Field only in
Business Partner
Field only in
Vendor /
Customer
Field in both BP
and Vendor /
Customer
© 2024 SAP SE or an SAP affiliate company. All rights reserved. See Legal Notice on www.sap.com/legal-notice for use terms, disclaimers, disclosures, or restrictions related to this material.
5 / 65
2. STEP BY STEP EXPLANATION
Even though we have to distinguish three cases for the field extension, the implementation steps are very
similar. The implementation involves the following main tasks:
• Extending the ERP data model
• Extending the MDG data model
• Generating the MDG data model specific structures
• Defining SMT mapping
• Implement CVI mapping (if applicable)
The main differences in the implementation approaches can be identified from the table below. During the
step “define SMT mapping” it is important to map to the right structures. If the field extension was made in
both business partner and vendor / customer you must additionally implement the CVI mapping (but only
SMT mapping to BP is necessary).
Implementation Steps Field only in
Business Partner
Field only in
Vendor/Customer
Field in both BP and
Vendor/ Customer
Extend ERP data model
Extend MDG data model
Generate MDG data model
Define SMT mapping 1 2 1
Implement CVI mapping
Table: Implementation steps for extending the MDG-S/C data model by a new field
SMT Mappings
1
MDG staging ↔ Business Partner
2
MDG staging ↔ Vendor / Customer
2.1. Extended Field Exists in Business Partner Only
You want to extend the MDG data model for Business Partner by additional fields. The fields are added to
the Central Data entity type as shown in the figure below.
5 / 65
2. STEP BY STEP EXPLANATION
Even though we have to distinguish three cases for the field extension, the implementation steps are very
similar. The implementation involves the following main tasks:
• Extending the ERP data model
• Extending the MDG data model
• Generating the MDG data model specific structures
• Defining SMT mapping
• Implement CVI mapping (if applicable)
The main differences in the implementation approaches can be identified from the table below. During the
step “define SMT mapping” it is important to map to the right structures. If the field extension was made in
both business partner and vendor / customer you must additionally implement the CVI mapping (but only
SMT mapping to BP is necessary).
Implementation Steps Field only in
Business Partner
Field only in
Vendor/Customer
Field in both BP and
Vendor/ Customer
Extend ERP data model
Extend MDG data model
Generate MDG data model
Define SMT mapping 1 2 1
Implement CVI mapping
Table: Implementation steps for extending the MDG-S/C data model by a new field
SMT Mappings
1
MDG staging ↔ Business Partner
2
MDG staging ↔ Vendor / Customer
2.1. Extended Field Exists in Business Partner Only
You want to extend the MDG data model for Business Partner by additional fields. The fields are added to
the Central Data entity type as shown in the figure below.