SAP BAPI Implementation
Overview
This feature lets DataTrust read data from SAP using SAP BAPIs. You pick a BAPI, fill in its inputs, and run it to get the data — which you can save and reuse.
This guide shows how, using both fixed values and variables.
Setting Up the SAP BAPI Query
Figure 1:
The DataTrust Cockpit (landing page) as the RDAdmin user.
Figure 2:
The navigation with Query Studio expanded and Query selected to open the Query Generator.
Figure 3:
The Query Generator (Query Builder) — the Connection drop-down is used to pick the SAP source.
Figure 4:
Searching for and selecting the ‘SAP ECC’ connection from the Connection drop-down.
Figure 5:
Setting the Query type to ‘SAP BAPI’ (instead of Single or Multiple Table).
Figure 6:
Selecting the BAPI program (ZFI_READ_ZVCOPAHELLO_NEW). Its Input Parameters (IV_COMPANYCODE, IV_MAX_ROWS) and Input Tables (ET_DATA, ET_RETURN, IT_SELECTIONS) are listed.
Running the BAPI with Fixed Values
Figure 7:
Entering the input parameter values — IV_COMPANYCODE = 1000 and IV_MAX_ROWS = 10000.
Figure 8:
Opening the IT_SELECTIONS input table (via the grid icon) to define selection criteria for the BAPI.
Figure 9:
The IT_SELECTIONS editor — a criterion (FISCALYEAR, Include, LT ‘Less Than’ 2004) is added and saved.
Figure 10:
Executing the BAPI (Run). The Results panel returns ET_DATA (7930 rows) for fiscal year 2003, along with ET_RETURN and IT_SELECTIONS.
Figure 11:
Saving the query as ‘SAP BAPI-Without using variable’; the confirmation toast appears and the Query Version is ‘Executable’.
Parameterizing the BAPI with Variables
Figure 12:
Replacing the fixed input values with RightData variables — IV_COMPANYCODE = ~~USR_Company Code## and IV_MAX_ROWS = ~~USR_Max Rows##.
Figure 13:
Executing the variable-based BAPI query; the Results return ET_DATA (1051 rows), resolved from the variable values at run time.
Figure 14:
Saving the query as ‘SAP BAPI using Variable’; the confirmation toast confirms it saved successfully.
Reusing the Query in a Query Chain
Figure 15:
The saved BAPI query reused in a Query Chain (QC-BAPI → Read SAP BAPI query → RD Output), executed successfully with the SAP data in the RD Output.