Skip to Content
0
Jun 18, 2020 at 08:38 AM

Adding custom field (reuse) to MDG BP data model BP_CENTRL and MDG UI BS_BP_Details_CU

2295 Views Last edit Jun 18, 2020 at 08:43 AM 2 rev

Dear all,

First of all thanks to the existing thread which Tamas started (https://answers.sap.com/questions/11894877/cannot-extend-mdgc-with-custom-field.html). It helped us to overcome similar issues and progress with our similar requirement.

I would like to share the experiences we made with our requirement since we have some open questions (see 3rd last paragraph below of my post):

Our requirement is to add a custom fields to the MDG data model in entity BP_CENTRL and in the MDG UI to the UIBB Business Partner Details/General Data (BS_BP_Details_CU). The field including a corresponding check table already existed within an Append Structure to the BUT000 table. So, we needed to add this field to the MDG data model and MDG UI using the reuse option.

For the configuration we used the following two How-To Guides: “SAP How-To Guide_ Extend MDG-S Data Model by a New Field (Reuse Option)” https://archive.sap.com/documents/docs/DOC-31885, mainly this guide but also the guide “SAP How to Guide Extend MDG-M data model by a new entity type erp table reuse option” https://archive.sap.com/documents/docs/DOC-47988 .

After adding the field to the MDG data model we activated the data model and then tried to generate selected data model specific structures for entity BP_CENTRL. Executing the generation we were prompted to enter a patch for a package. At this point of time from my point of view it would have been important to specify an existing custom package like e.g. Z_MDG. However we entered the corresponding standard package when prompted (/MDGBP/MDG_BS_BP_STRUCTURES). Doing so we experienced following generation error “TADIR entry for CI_MDG_S_BP_BP_CENTRL could not be created”, “Delivered structures in namespace /MDG* are not generated” (s. screenshot 1). Following the recommendations in the other thread (see above) using SE11 as good as we could we manually activated corresponding customizing includes CI* in corresponding structures of BP_CENTRL: *PDF_BP_CENTRL, * PP_BP_CENTRL, * ES_BP_CENTRL, *FC_BP_CENTRL, *FP_BP_CENTRL, *KY_BP_CENTRL, *EX_BP_CENTRL. The other thread (see above) is also recommending to add the corresponding customizing includes CI* to the structures in case they were missing because of the generation errors. We only activated the customizing includes and did not add them to the structures where they were missing because our impression was that they were existing in the most important structures. Most important structure for our requirement seemed to be PP_BP_CENTRL (Mapping of Reuse Active Area).

In parallel we received the recommendation that mentioned TADIR generation error can be resolved by specifying a custom package for customer include in the BP data model customizing (as described in the MM reuse fields extension guide on pages 23ff). In addition the custom package should be entered in the “package” column of generate selected structures. We did not want to add the package in the “package” column of generate selected structures because that was not mentioned anywhere in the MM guide. Instead we entered it in the data model customizing as the MM guide was suggesting. When trying to activate the BP data model afterwards we received a message saying that a custom Prefix/Namespace needs to be set as well in the same customizing (s. screenshot 2). We choose namespace /ZMDGBP/. Note: This custom namespace is not existing in the system. It would have been time consuming and difficult to request (key request and approval of end client needed) and also not needed to set it really up for this project. When we activated data model BP again with those two settings we received a high number of TADIR activation errors (s. screenshot 3). In addition we found that in generation of data model specific structures a high number of structures are now showing namespace “/ZMDGBP/” (s. screenshot 4, e.g. FC_BP_CENTRL). Afterwards generation of selected structures for BP_CENTRL terminated with an error regarding not existing namespace /ZMDGBP/. We researched and found that there are quite many MDG Community discussions of people which are also affected by those issues and even customer OSS messages. Some of those people also did follow corresponding steps in the MM guide. Those people had not-existing Namespace namespace "/ZMM/" appearing in their generated structures afterwards. We have now opened a SAP OSS message and asked for a cleanup report since we are currently not able to activate our data model BP nor can we generate the BP_CENTRL specific structures. Furthermore we heared that the structures which got not-existing namespace /ZMDGBP/ assigned are unused structures. Anyone able to confirm this ? And what will happen if we will start using them and they remain in the custom namespace ? In parallel to the SAP OSS message we received the information we would need to “remove” the structures which now show not-existing prefix/namespace “ZMDGBP” from the “nodes” to be able to activate the MDG data model and selected BP_CENTRL structures again. Anyone able to tell what is meant by “removing the nodes from the structures” and where and how this can be done ? Does it mean to add the the standard prefix/namespace /MDGBP/ in Data Model Specific Structures section of the MDG data model customizing for all those structures which now show “ZMDGBP” ? for each affected entity type (s. screenshot 5) ?

Coming back to the requirement to add the custom field since we initially could add the field to the MDG BP data model and generate the selected BP_CENTRL structures even with errors and manual corrections, before things got worse with the namespace errors, we could do the SMT mapping for the field and we were also able to add the fields to the corresponding MDG UIBB. Key to have the field available for the SMT mapping and in the MDG UI customizing add elements drop down seems to be to make sure that the field is included in structures CI_EEW_BUT000 and CI_EEW_BUT000_X. This is where MDG seems to expect custom BUT000 fields for our particular extension requirement. That forced us to remove the existing BUT000 Append structure for the existing reuse field and add the field directly in structures CI_EEW_BUT000 and CI_EEW_BUT000_X. Once a field is added to structure CI_EEW_BUT000 it will automatically be included to table BUT000. In our particular case we did not need to include the field in the TCODE: genil_model_browser as some people in this thread were suggesting. It already appeared included there. After adding the field to the MDG UI we experienced the issue that selected values from the fields check table were disappearing. In our case this was caused by another field in structures CI_EEW_BUT000 and CI_EEW_BUT000_X having the same data element. We received the solution hint from the following own separate blog for discussing reasons for disappearing data in MDG custom fields https://blogs.sap.com/2013/11/07/mdg-some-reasons-why-data-disappears/

From my point of view there should be a troubleshooting chapter added to those two SAP How to guides mentioning all those issues and potential issues which the people in this thread were running into.

Regards,

Michael

c-workscreenshot1.pngc-workscreenshot2.pngc-workscreenshot3.pngc-workscreenshot4.pngc-workscreenshot5.png

Attachments