|Home • Trainings •Quiz • Tips • Tutorials • Functional • Cert Q's • Interview Q's • Jobs • Testimonials • Advertise • Contact Us|
SAP-BODS Integration using BAPI
By Praveen Addanki, HCL-AXON
We can call SAP ERP or R/3 Remote
Function Call (RFC) enabled functions, including Business Application
Programming Interface (BAPI) functions, from queries inside data flows.
A Remote Function Call is really what the word suggests: You call a function but
it is remote rather than part of your code. This is the standard way how 3rd
party’s tools access SAP, both for read and write. All RFCs meant to be used
for business reasons, their function name starts with the text BAPI_XXXX like
BAPI_ABSENCE_CREATE or BAPI_ABSENCE_GETDETAIL, both meant to create or display
employee’s absence records in HR.
you design data flows with BAPI calls against one version of SAP ERP or R/3,
then change data stores to a later version of SAP ERP or R/3. Data Services
allows this without the need to re-import the BAPI. Any new parameters added to
the function call, including additional columns in table parameters, are added
automatically to the call and filled with NULL values. Thus Data Services allows
you to design jobs that are portable between SAP ERP or R/3 systems. After you
import the metadata for an SAP ERP or R/3 function, the function is listed in
the Functions category of the ERP or R/3 data store. You will also see the
function in the function wizard, listed under the data store name.
Services supports tables as input and output parameters for SAP ERP or R/3 RFC
and BAPI functions. The function import process automatically includes the
metadata for tables included as function parameters.
you import the metadata for an SAP ERP or R/3 function, the function is listed
in the Functions category of the ERP or R/3 datastore. You will also see the
function in the function wizard, listed under the datastore name. To call a BAPI
depends on the requirement; here in this document we have considered an example
of creating a CONTRACT using ‘BAPI_CONTRACT_CREATEFROMDATA’. For this BAPI,
we need to send mandatory input and Tables parameters to create a CONTRACT.
specify a table as an input parameter to a function, the table must be an input
to a query, either as a top-level input or nested under the top-level. The table
must also be available in the FROM clause of the context where you call the
function. Data Services maps columns in the input schema by name to the columns
in the table used as the function input parameter. You need only supply the
columns that are required by the function. At validation, if Data Services
encounters type mismatches between supplied columns and the function signature,
it attempts to convert the given type to the expected type. For type mismatches
that it cannot resolve, Data Services produces validation errors.
Importing the BAPI:
This entire documentation refers to IDES SAP system, refer the below screen shot
The following Process indicates how to
import the BAPI.
Processing the BAPI:
In this BAPI the mandatory importing and Tables parameters required
to create a Contract are:
We can call this BAPI in a query transform and give the inputs as shown below. Before calling the BAPI create a output schema for passing the Tables parameter as shown below.
Inside the Query from the above screen shot.
the BAPI inside the Query_1 as shown below.
Please send us your feedback/suggestions at webmaster@SAPTechnical.COM
©2006-2007 SAPTechnical.COM. All rights reserved.
product names are trademarks of their respective companies. SAPTechnical.COM
is in no way affiliated with SAP AG.
Graphic Design by Round the Bend Wizards