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

Regarding BAPI

Former Member
0 Likes
741

Hi All,

I went through some documents related to BAPI.It is mentioned that BAPI's are used to exchange data between SAP components or between SAP and Non-SAP components.I understand SAP components includes : 1.SAP technology,2.Basis System 3.Interfaces 4.R/3 Application modules.

We do we use BAPI's for data exchange b/n SAP components,why can't we do it through normal function modules.Can you kindly elaborate on the advantages of using BAPI and in what situations we need to go for it.

4 REPLIES 4
Read only

Former Member
0 Likes
717

Hi,

BAPIs are special, remote-enabled methods of a business object, and are implemented as RFC-enabled function modules.

BAPIs can perform various functions such as:

- cretaing an object

- querying the attributes of an object

- changing the attributes of an object

You can use BAPIs for different applications. For example:

­Internet application components: Where individual R/3 functions are implemented on the Internet or Intranet for users with no R/3 experience.

­Building R/3 components Communication between the business objects from different R/3 components (applications).

­VisualBasic / JAVA / C++ : External clients access R/3 data and processes through the BAPIs.

You can access BAPIs from external clients like methods access objects, which are themselves an instance in the client.

SAP guarantees that no incompatible changes will be made to the interfaces of BAPIs.

You can also use BAPIs within the R/3 System to access business data. This makes it easier for customers and partners to add to the functions offered by the system.

Displaying data that is transmitted to a BAPI or that is returned from a BAPI must be done from the calling program.

The return parameter RETURN contains success or error messages for the BAPI, and depending on the SAP R/3 Release has the dictionary structure BAPIRETURN, BAPIRETURN1, BAPIRET1, BAPIRET2 or BAPIRET2_FIX. The (common) relevant fields of these structures are:

TYPE (Message type: S(uccess), E(rror), W(arning), I(nformation) ) ;

ID (message class) ; NUMBER (message number) ; MESSAGE (message text) ;

MESSAGE_V1 , MESSAGE_V2 , MESSAGE_V3 , MESSAGE_V4 (message variables)

If the transmission is successful, RETURN is either completely empty (all the fields have their initial fields for their types), or only the TYPE field has the value 'S'. Refer to the documentation to find out which applies to the BAPI you are using.

Just go thru some more documents of BAPI like BC 415.

And also read some manuals from saptechnical.com.

I think it would be helpful for u.

Kind Regards

Yogesh

Read only

GauthamV
Active Contributor
0 Likes
717

hi,

check these.

[http://help.sap.com/saphelp_46c/helpdata/en/7e/5e115e4a1611d1894c0000e829fbbd/frameset.htm]

[https://forums.sdn.sap.com/click.jspa?searchID=18929997&messageID=4855031]

Read only

Former Member
0 Likes
717

hi Subasree,

If you want to access a SAP business object you should always go for the BAPI and not use any apparently similar RFC function module. Only the BAPI will ensure that all incoming data are validated and that the business object is after any CREATE or CHANGE is in a consistent state when you use it in a dialog transaction.

Just go through the following link:

Hope this will help.

Regards,

Nitin.

Read only

Former Member