cancel
Showing results for 
Search instead for 
Did you mean: 

Orders getting saved eventhough Contact person name or number entered does not exist in the business partner master data

leandros
Explorer
0 Kudos

Hi everybody, I have the following problem, when I create an order and in the field "Contact Person" I enter a name or number that does not existe in the bp master data, the system let me save the order. I want this to be blocked. This field should be filled only with existing BPs, selected from the matchbox. So If the field is blanck or filled with not existing bp, the system shouldn't let me save the order giving an error message.

Hope you can help me.

Regards

Leandro

Accepted Solutions (1)

Accepted Solutions (1)

GopalakrishnanS
Participant
0 Kudos

Hi Leandro,

Try to implement the ORDER_SAVE BAdI definition. Include your logic to check the BP is existing one or not in the method 'CHECK_BEFORE_SAVE'.

Regards,

Gopalakrishnan Selvarj.

Answers (2)

Answers (2)

leandros
Explorer
0 Kudos

Hi  Gopalakrishnan and Navn, thank you both for the answer, is really helpful I'll put it into practice... Isn't there any standard customizing for validating this without programing?

Regards

navn_metts
Active Participant
0 Kudos

Hello,

As suggested by selvaraj you have to implement the ORDER_SAVE badi and the method "check_before_save" method.

In this method perform the validations you want for that BP and if the validation fails raise the exception like below.

raise do_not_save.

this will not allow the orders getting saved.

Br,

Navn