To access the HANA-based application logic in ABAP, you have to create the corresponding ABAP repository objects that are
already implemented at database level as HANA database procedures.
Prerequisites
- The AS ABAP system runs on a SAP HANA database.
- The corresponding database procedure already exists in the HANA repository of the AS ABAP system.
Procedure
- In your ABAP project, select the relevant package node in the Project Explorer.
- Open the context menu and choose
to launch the proxy creation wizard.
- In addition to the Project and Package, enter the Name and Description for the proxy to be created.
- Enter the name of the appropriate HANA database procedure that has already been created in the ABAP system in question.
Then choose Next.
Tip
When editing the name of the HANA Procedure, you can benefit from the content assistant functionality by
pressing Ctrl + Space in the corresponding field. Note that entire name of the database procedure comprises the HANA package name (first part) and the actual procedure name.
Note
The wizard automatically proposes a name IF_<PROXY_NAME> for the ABAP interface to be created.
This interface contains the ABAP data type definitions.
However, you can change the proposal in keeping with your own naming conventions for ABAP object types.
Figure: First wizard page when creating a database procedure proxy
Note
The ABAP Development Tools support the recommendation that only one proxy should be created for each single HANA database procedure:
Every time you want to create more than one proxy for a single HANA database procedure,
you will be faced with a corresponding warning message in the creation wizard.
Figure: Warning when creating more than one proxy for a HANA database procedure
- Assign a transport request.
- Choose Finish.
Results
In the selected package, the back-end system creates an inactive version of a proxy for the corresponding HANA database procedure.
In addition, a corresponding ABAP interface (in our example: IF_CURRENCY_CONVERSION) with data type definitions for the proxy is also created in the same package.
As result of this creation procedure, the editor with the new proxy will be opened.
The proxy definition already includes a default mapping of parameter names and types from the database procedure and the parameter names and data types to be used in ABAP.
In the Project Explorer, the new proxy is added to the Dictionary folder of the corresponding package node.