Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

WBS Element and Plant Validation In Purchase Requistion.

er_rajchowdhary
Explorer
0 Kudos
305

Hi Everyone,

I want to put validation between wbs element and plant.

If the web element and plant match, then only the document is saved, otherwise it will give an error.

Regards,

Raj Kumar

1 REPLY 1

raymond_giuseppi
Active Contributor
0 Kudos
257

Use BAdI ME_PROCESS_REQ_CUST method PROCESS_ACCOUNT:

  • Read account information with IM_ACCOUNT->GET_EXKN, (WBS Element = RE_EXKN-PS_PSP_PNR)
  • Read PR item with IM_ACCOUNT_REF->GET_ITEM, plant with RE_ITEM->GET_DATA (Plant = RE_DATA-WERKS)
  • Check your "matching" rules and raise error with macro such as mmpur_message_force of include mm_messages_mac when failed.