SAP DATABASE PROCEDURE PROXY

Get Example source ABAP code based on a different SAP table
  


ARTICLE

Database Procedure Proxy
For each database procedure, database procedure proxies can be created as repository objects in ABAP Dictionary. This makes it possible to address the database procedure in the statement CALL DATABASE PROCEDURE. A database procedure proxy can be created as follows:
Interactively in the ABAP perspective of the ABAP Development Tools
In the program, using an API. This API makes it possible to create and delete database procedure proxies. It is based on objects from the class CL_DBPROC_PROXY, accessed using the interface IF_DBPROC_PROXY_PUBLIC_API. A API of this type is created using the factory method GET_PROXY_PUBLIC_API from the factory class CL_DBPROC_PROXY_FACTORY. A further factory method, GET_PROXY_QUERY_API, makes it possible to create another API, which is used to get information about database procedures and database procedure proxies.
The database procedure proxy defines the mapping between the database types of the parameter interface of the database procedure and ABAP data types. The parameter names can also be changed here. A database procedure interface is generated for each database procedure proxy. Appropriate ABAP types are declared in this interface.

Notes
The interfaces and classes from the database procedure proxy library are documented in Class Builder. They are accessed most easily from the factory class CL_DBPROC_PROXY_FACTORY .
If, when mapping of parameter types between database types and ABAP types, a reference is made for the latter to data types of ABAP Dictionary and such a dictionary type like this is modified, the database procedure proxy cannot be generated automatically. This can cause database inconsistencies. In such a case, the database procedure proxy must be generated again explicitly.

Example
The example Database Procedure Call uses a database procedure proxy created in the program to call a database procedure created using ADBC.