Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

difference between lsmw using BAPI & lsmw using IDOC?

Former Member
0 Likes
2,097

HI everybody

can anybody tell me difference between lsmw using BAPI & lsmw using IDOC?

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
1,398

the main diffrence is:

BAPI is synchoruns i.e it will return the message whther success or not.

in IDOC, it is asynchronus, ie system doesn't wait for response.

revrt back if anyissues.

regards,

Naveen

4 REPLIES 4
Read only

Former Member
0 Likes
1,399

the main diffrence is:

BAPI is synchoruns i.e it will return the message whther success or not.

in IDOC, it is asynchronus, ie system doesn't wait for response.

revrt back if anyissues.

regards,

Naveen

Read only

Former Member
0 Likes
1,398

The main difference is that an Idoc procsessing function module is triggered in the case of LSMW using IDOC, and a BAPI gets triggered in case of LSMW using BAPI.

The Idoc processing function module may in turn call the BAPI only.

See the below links:

LSMW using BAPI: http://www.saptechnical.com/Tutorials/LSMW/BAPIinLSMW/BL1.htm

LSMW Using IDOC:

http://www.saptechnical.com/Tutorials/LSMW/IDocMethod/IDocMethod1.htm

Regards,

Ravi

Read only

Former Member
0 Likes
1,398

Hi,

BAPIs are synchronous while IDOCS are Async.

BAPIs are configure with ALE and message types in LSMW in order to make them Asynchronous.

BAPIs are normally called synchronously in order to get feedback immediately.A synchronous call will only work if the system we want to access is up and running.For some purposes like data transfer, SAP wanted BAPIs to invoke asynchronously so that the calling application could proceed even if the remote system was currently unavailable.

Hence these BAPIs are linked to ALE (Application Linking and Enabling),an asynchronous message passing mechanism with guaranteed delivery.ALE uses Idocs as the containers for messages. Idocs are instances of Idocs types, which in turn are associated ALE message types.

Hope this is clear

Thanks and regards.

Read only

Former Member
0 Likes
1,398

IDocs and BAPI are very different, so it should be easy to choose between them depending on your requirements.

IDOCS

Advantages

System can work even if target system not always online. The IDoc will be created and sending will just continue once you get connected to the other system.

No additional programming required. You just need to set up the configuration.

Disadvantages

Receipt/processing on the target system may not be immediate.

The sending system has no way to know whether the target system actually received what you sent (unless you use ALE).

If there is no SAP standard IDoc available for your requirement, it's harder to create a customized IDoc than a customized BAPI.

BAPIS

Advantages

You can tell if your sending was successful or not

Sending to/processing on the other side is immediate

Easier to create your own BAPI than your own IDoc

Disadvantages

Will only work if you have an active online connection.

Some programming required to call the BAPI.

Others interface methods you might also want to consider are ALE and RFCs.