cancel
Showing results for 
Search instead for 
Did you mean: 

LSMW - Using a BAPI

Former Member
0 Kudos

Hi All,

I am setting up a LSMW project, and need to use a BAPI for processing the data. However, when I enter the BAPI info, I get an informational message:

Maintain the default values for IDoc inbound processing.

I'm not exactly sure how to configure this for my system. My question is: Is the IDoc inbound processing setting critical for a LSMW project? I just need the system to read a text file, map it to the BAPI, and process it. I don't need to use IDocs at all.

Thanks!

Regards,

R.D.

Accepted Solutions (0)

Answers (2)

Answers (2)

Former Member
0 Kudos

Hi, try to answer your question, hope my reply is helpful.

First, though the LSMW have 4 way to inbound include IDOC and BAPI, the IDOC mentioned in BAPI is different with IDOC way.

If you want to configure in a BAPI way, first you need to create a ALE message for a BAPI, you can do this in the BAPI explore, show a BAPI, and double click the ALE message field on the screen, or though the tcode BDBG.

After you create the ALE message for this BAPI, the server will automatively generate a new ALE idoc message type, and two function inbound and outbound to handle this kind of idoc. You only need to remeber the new ALE message type name.

Next, you can configure the LSMW for BAPI ,(if you don't do the first step, the BO can't been choosen in the LSMW).

Then you choose the BO and method appropriately. The target structure of this LSMW scenario is the IDOC type of you create for this BAPI.

Then left steps are similar with normally LSMW step. Something specially, you will find the ALE IDOC message is very likely the interface you can BAPI, but added a control header for IDOC.

As the LSMW only inbound in the local, the control header should keep the default value LSMW set, a file port BAPI assigned to the send port.

If everything goes well, when you run LSMW scenario, the target structure will be filled, and send to the ALE layer, just generate a ALE IDOC and send to system, the effect of it just like you call BAPI, but in a asynchronous way.

That's all. thanks a lot

Former Member
0 Kudos

Hi All,

Thanks for your quick replies. I will get in touch with a BASIS person to help me with IDoc ports.

Thanks!

R.D.

former_member214131
Active Contributor
0 Kudos

Hello,

In LSMW the BAPI uses the ALE Interface to load the data into SAP.

So you need to maintain ALE parameters viz., File ports ( Usually by name - LSMW ), Partner Type (LS), Partner Number / Partner Profiles ( Usually by name - LSMW ) in the menu path 'settings -> IDoc Inbound Processing' of the LSMW initial screen.

Take the help of BASIS people in your project if you do not have sufficient authorizations.

Check out this link:

http://help.sap.com/saphelp_erp2004/helpdata/en/d4/0a43a124e8924ea890cf0855860db5/content.htm

For more info of using BAPIs in LSMW, check out Unit 11 of BC420.

Hope this helps you.

Regards, Murugesh AS

Former Member
0 Kudos

Hi Murugesh,

I have a question on LSMW with Inbound idoc processing.

If i have 4 field like matnr, UOM , Description and qty it means its a plane structure flat file.

Since my basic idoc type would be matmas02 and its a complex data structure how i am going to map it with my source structure which i designed like my plane flat file.

Please suggest me its very urgent, you can mail me on my id tiwari.manoj@gmail.com

Thanks & Regards,

Manoj Tiwari