cancel
Showing results for 
Search instead for 
Did you mean: 

MDG-S: Extending AD_POSTAL Entity with custom fields

Varu
Explorer
0 Kudos

Hello,


We have a requirement to extend standard entity AD_POSTAL with custom fields and save the data in active area.

For that we have done the following steps:


1. Extend ADRC table (active area) with custom fields.
2. Extend structures BUS_EI_STRUC_ADDRESS and BUS_EI_STRUC_ADDRESS_X with custom fields. These structures will be used in SMT

    mapping.
3. Extend AD_POSTAL Entity with custom fields (MDGIMG)
4. Generate data model specific structures for AD_POSTAL (MDGIMG).
5. Extend SMT mapping -
      --BP_AD_POSTAL_2API
      --BP_AD_POSTAL_2STA
6. Enhance UI configuration BS_BP_ADDRESS to display custom fields.


For testing, created a CR and approved it.

But data is NOT getting saved in active area i.e. ADRC table.

Please Suggest.

Accepted Solutions (0)

Answers (5)

Answers (5)

xavier_abap
Explorer
0 Kudos

Hi Karan,

Could you please let me know how you have solved this issue...?

I am able to save the data to Staging area(including custom fields),but when the final approval happens ADRC gets updated except the custom fields.I also did all the steps that you mentioned above.

Did you enhance any of the classes CL_BS_API_ADDRESS_MDG_BP or CL_MDG_BS_BP_HANDLER?

I am struck up with the same issue that you had.

Regards,

Xavier

Former Member
0 Kudos

Hi Karan,

First Check whether data is getting stored in Staging area or not after submission of change request.

Regards,

Sudhir Wakodikar

0 Kudos

I think only step u r missing is enhancing the access class , check CL_MDG_BS_BP_HANDLER it has methods for ur entity .

Former Member
0 Kudos

Hi Karan,

I have same problem in Business Partner.
You could fix this issue? If yes, how?

I can send you a document (my procedure to added field in AD_POSTAL) by email?

Regards.

former_member196830
Active Participant
0 Kudos

Hello Karan,

Did you do an enhancement spot for the CVI mapping? See if you follow this document, perhaps you'll be able to sort it out: http://scn.sap.com/docs/DOC-31884

Regards,

Boris

Varu
Explorer
0 Kudos


Hello Boris,

I am following the same document. And as per the document CVI mapping should be implemented to

facilitate data transfer from BUT000 to the LFA1 / KNA1 tables.

If data is to be stored in BUT000 or LFA1 only then there is no need to implement CVI mapping.

We need to store data in ADRC table (as standard SAP is doing for fields of UI configuration BS_BP_ADDRESS).

Am I missing something?

Please suggest.

Regards,

Karan Arora




former_member196830
Active Participant
0 Kudos

Hey Karan,

You are right, the document is an example for the BUT000 and LFA1 tables.

In your case you are extending the ADRC table. I believe you should have a look at the access class that saves the Address information and see if you have to do an explicit enhancement to any method.

I think it's CL_BS_API_ADDRESS_MDG_BP. Keep in mind that the saving takes place in the background, it's being ran with another user, so debugging it is done through SM50... a breakpoint won't do it.

Are you saying that the whole address is not saved in the ADRC table or only the custom fields are not updated? Also, did you extend the ADRC table with custom fields or only the structure (using existing ADRC table fields that are not in the model)?

Hope that helps,

Boris