on 12-20-2014 7:43 AM
Hi all,
I'm trying to write a report for mass rejection of open sales order. I use BAPI_SALESORDER_CHANGE. The problem is when there are same materials as different line items of same sales order, bapi throws an error that material already entered.
Eg:
SO:
77997
Items:
000010 H1PST
000020 H1PST
000030 H1SPSN
With the above details if fill the header as well as items and when I execute, it says item already entered in 20. How should I do this?
Hi guys,
Thanks for the reply. After some explorations I found out that some one had done some enhancements in VAXX tcodes that will restrict the user not to enter one material more than once unless it is any form of subsidiary material. There was some logical issue with the code that lead to this error. Now all the things are rectified and perfected. Thanks for your support.
Regards,
Ahamed Yashif
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Dear Ahamed,
Having the same material in line items 10 and 20 shouldn't be an issue.
I created a test and was able to apply reason for rejection in an order with the same material in two or more line items.
Try a test sequence of BAPI_SALESORDER_CHANGE and BAPI_TRANSACTION_COMMIT from transaction SE37 with the following fields:
SALESDOCUMENT 77997
ORDER_HEADER_INX-UPDATEFLAG U
ORDER_ITEM_IN-ITM_NUMBER 000010
ORDER_ITEM_IN-REASON_REJ 01
ORDER_ITEM_IN-ITM_NUMBER 000020
ORDER_ITEM_IN-REASON_REJ 01
ORDER_ITEM_IN-ITM_NUMBER 000030
ORDER_ITEM_IN-REASON_REJ 01
ORDER_ITEM_INX-ITM_NUMBER 000010
ORDER_ITEM_INX-REASON_REJ X
ORDER_ITEM_INX-ITM_NUMBER 000020
ORDER_ITEM_INX-REASON_REJ X
ORDER_ITEM_INX-ITM_NUMBER 000030
ORDER_ITEM_INX-REASON_REJ X
I hope this helps.
Regards,
Ian Kehoe
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Yasif ,
obviously system will through the error , why because already you entered the material in 1st line again you are adding the same . instead of that add the more quantity to the same line item(material) for avoiding the redundancy.
2) if you want to bi-forget the things means you have to follow grid/batch rules , by using schedule lines. i.e 10 line item only material -- H1PST -- schedule line item 1 -batch 80g qty 100, S.Line item 2 - 100g qty 10, ..etc.
Regards,
Krishna
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
you can use Transaction -MASS by updating reason for rejection at the Item Level
This can also be used as background processing
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
85 | |
7 | |
6 | |
4 | |
3 | |
3 | |
3 | |
3 | |
3 | |
2 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.