Skip to Content
0

BAPI_PO_CREATE1 LSMW for Multiple PO's and PO items

Dec 11, 2017 at 02:08 PM

47

avatar image
Former Member

We want to upload Open Purchase orders using LSMW and BAPI_PO_CREATE1, but I can't see how to structure the input from a one to many level between EKKO and EKPO.

The table POITEM only have the key value PO_ITEM (EBELP) and not PO_NUMBER (EBELN),thus if I create two input files on tow levels for header and items, there is no way to indicate which items belong to which header records. This problem is compounded when you add the Pricing conditions (POCOND).

Therefore it looks like you can only upload one PO Header with its various items, unless someone have a workaround for me.

10 |10000 characters needed characters left characters exceeded
* Please Login or Register to Answer, Follow or Comment.

2 Answers

avatar image
Former Member Dec 11, 2017 at 07:19 PM
1

Try to create purchase order manually using me21n and see what it does.
Or continue your LSMW using:
Fill POHEADER-ITEM_INTVL and POHEADERX-ITEM_INTVL as following:
POHEADER-ITEM_INTVL = '0000'.
POHEADERX-ITEM_INTVL = 'X'.
Regards.

Share
10 |10000 characters needed characters left characters exceeded
Jürgen L
Dec 11, 2017 at 02:57 PM
0

You have to distinguish between the data that is coming from your source and the data that is created from the conversion step.

Of course you need to have a common identifier (can be the PO number from legacy system) to let SAP (even more the people who maintain several spreadsheets) know which items belong to which header and which condition to which item.

Using a field in the source structure does not automatically mean it has to be in the target structure too. If you use it just depends on its availability in the target structure and on your field mapping.

Share
10 |10000 characters needed characters left characters exceeded