2024 Aug 23 9:01 AM
Hi All,
When creating a PR, I want to map the email address assigned to the SAP ID of the PR requisitioner to the Email field under Item -> Delivery Address -> Address Details -> Communication. I looked into enhancement MEREQ001 but couldn't find a variant that allows assigning to the Communication Email. Has anyone encountered this issue before or can provide some guidance on where to look?
Thanks
2024 Aug 23 2:15 PM - edited 2024 Aug 23 2:21 PM
Are you running S/4 or non-S/4 (ECC)? There might be 2 approaches here, depending on your System, the Nmbr of PR-Creators, etc.
Under normal circumstances, I assume you have maintained a number of Delivery Addresses via Trx. "MEAN". If you only have a limited number or PR-creators, you could consider creating new "MEAN"-records for a limited set of SAP-Users initiating those PR's, including their e-mail. That set of "MEAN"-records could be fetched in Custom Logic, for instance in User Exit "EXIT_SAPLMMDA_001" ... The UserExit is called in FM "MM_DELIVERY_ADDRESS_PROPOSE" and can be used to 'overrule' the Standard Address-proposals with your "SAP-ID"-MEAN ... You could experiment by putting a Breakpoint in the FM "MM_DELIVERY_ADDRESS_PROPOSE" and see what happens when overruling the "E_ADRNR" Output ... If this AddressNmbr however does not get passed / shown in the UserInterface, you will be generating an error of Msg-type "ME 083". Then I would suggest using BAdI "ME_PROCESS_REQ_CUST" and its methods to influence the "ADRN2" field on the PR-Item level (there are "Getter and Setter" Methods for the Item data) ...
Using the BAdI and / or UserExit should get you a long way towards a solution (having also maintained "MEAN"-records for a limited set of PR-Creators).
On a S/4-System however, there are a number of new BAdIs that are interesting to investigate. In that case, I would focus on using the BAdI "MM_PUR_S4_SSPPR" (or "MM_PUR_S4_PR", preferably the first). SAP-Note 2950092 - Delivery Address defaulting in "Create Purchase Requisition" and "My Purchase Requisitions... offers info on the trigger / use of the BAdI and includes sample code to Address your Issue.
Hope this helps
Nic T.
2024 Aug 27 3:23 AM
Thank you for the response. I will refer to your answer and look into it.