cancel
Showing results for 
Search instead for 
Did you mean: 

PO creation using LSMW through batch input method

Former Member
0 Kudos

Hi, I am new to working with LSMW and i have completed a project for creating purchase orders using the direct data input method. I need to do the same using batch input method, however in the maintain structure relationship step, it is only allowing me to assign one structure to the recording that i have done, however in po creation we need separate (nested) structure for header and line item, could anybody help me past this please?

View Entire Topic
christian_wohlfahrt
Active Contributor
0 Kudos

Hi Rudra!

Transaction ME21 is little bit old and transaction ME21N (because of enjoy technic) can't be handled correctly by batch input. What did you record?

To your question: you have a fixed number of positions in your recording, that's what you can fill currently. If you want to have a dynamical number of positions, you need to have a dynamical creation of the necessary lines of the batch -> use the standard direct input or the BAPI method.

Regards,

Christian

Former Member
0 Kudos

Hi Christian,

I used ME21 for the recording, and of course i have done the same with direct input, was just trying to figure out if it was possible to create transaction data in LSMW like purchase orders or sales orders using batch input, i have used batch input method to create master data like material master and customer master.

christian_wohlfahrt
Active Contributor
0 Kudos

Hi Rudra!

OK, now you just know, why you have only one line, not multiple PO item lines. To get a dynamic number of items, you need a complex program - just like standard direct input.

If you need a field, which is not part of this program, don't try to write your own program for batch input - it's just to much work before you have a good result.

You can use Bapi method instead with BAPI_PO_CREATE1. This can handle a lot of fields and there is some documentation available how to fill the Bapi.

If this looks to complicated in the first moment, think about creation of POs via direct input and a small batch recording to change your additional field(s) afterwards. (You can select EKPO table to generate list of 'wrong' migrated orders for input in LSMW.) Use field 'Item' in the bottom of ME22 to position your desired line in first screen line, just change one PO-line after one other (every time a 'save' -> no problem with different number of lines / PO).

Regards,

Christian