Skip to Content

Validation of ME21N

Nov 29, 2016 at 01:02 PM


avatar image

if multiple entries exists with same plant for a same material number then system should show a error message.

I found the BADI to be ME_PROCESS_PO_CUST..Method PROCESS_ITEM. facing some coding issues, need some help in code regarding the same.

Please tell me how do i do this?



10 |10000 characters needed characters left characters exceeded

Hi Teja,

Which issues are you finding?


Hi simone,

Step for validation for material and plant of duplicate multiple line item entries in coding in PROCESS_ITEM.

Bhanu Theja Katabathuni

So are you asking for the code? It's not fair and correct: it should be YOUR job find it out.

And there are tons of threads for this.


no i was asking whether the step of method PROCESS_ITEM is the place where we write the code for validation of item level ? or any other methods to change and also is it necessary to maintain the configuration table?

* Please Login or Register to Answer, Follow or Comment.

1 Answer

Raymond Giuseppi
Nov 29, 2016 at 03:23 PM

You can start from PROCESS_ITEM, but you need to read every item, so can be easier from CHECK method (executed before save) and better for performance, but error is triggered later, so your choice.

In CHECK get the list of item from IM_HEADER, lt_items = im_header->get_items( ), then for each item read current values : LOOP AT lt_item ASSIGNING <item>, <item>-item->get_data( ) and look for duplicate.

From PROCESS_ITEM get header with lo_header = im_item->get_header( ) and perform like in CHECK method.


Show 1 Share
10 |10000 characters needed characters left characters exceeded

Thanks Raymond.