Connecting SAP HANA on-premises to SAP Cloud Platform
Integration (CPI)
Connecting SAP HANA on-premises to SAP Cloud Platform Integration (CPI) is a crucial step in
establishing a seamless data flow between on-premise and cloud-based systems. This
integration allows organizations to leverage the power of cloud-based integration
capabilities while maintaining access to their existing on-premise HANA databases.
This document will provide a comprehensive guide on how to achieve this connection,
covering essential steps, configurations, and potential challenges. By following the outlined
procedures, you can effectively establish a bridge between your on-premise HANA
environment and CPI, enabling efficient data exchange and process automation.
iFlow
In order to Fetch Data from the SAP Hana Database from CPI iFlow - you need to complete
the following configurations. Step A and B as mentioned in the following diagram.
Overview
A. Cloud Connector
Cloud Connector is a software application that acts as a bridge between cloud-based
services and on-premises systems. It establishes a secure connection, allowing these systems
to communicate and exchange data seamlessly.
Login into the Cloud Connector Application and establish the connection for Cloud to On-
Premises system
Map the Hana Server into the Cloud Connector using TCP Protocol
Provide Internal IP and Port , Provide Virtual IP and Port
Note down the Virtual IP and Port ( this will be used in the JDBC Connection inside
the CPI subaccount)
Cloud Connector - Map External System
To Add new System - you need to provide details as below:
1. Backend Type : SAP - Hana
2. Protocol : TCP
3. Internal IP & Port
4. Virtual IP & Port
Once saved, you can verify the connectivity test by checking the Check Availability icon - that
will shows Reachable or Not-reachable.
Please note down : The Virtual IP and Port
B. Cloud Platform (CPI Account)
SAP Cloud Platform Integration (CPI) is a cloud-based integration platform as a service. CPI
provides a flexible and scalable solution for integrating cloud and on-premise applications,
facilitating seamless data exchange and process automation.
Login into the CPI Subaccount and Create the new JDBC Material / Connection.
Create the JDBC connection
Provide the JDBC URL as following format jdbc:sap://virtualIP:virtualPort/?
databaseName=myhanadb where virtual IP is the virtual IP you mentioned in cloud
connector in step A, virtual port is the virtual port you mentioned in cloud connector
in step A
JDBC Material Create
While adding JDBC, you need to provide the following details
1. Name : name as per your wish
2. Description : as per your wish
3. Database type : SAP Hana Platform (on premise)
4. User ID and Password : your database userid and password
5. JDBC Url : jdbc:sap://virtual ip:virtualport/?databaseName=your database name
Finally, in the iflow, you use JDBC adapter and in the properties tab, you mention the JDBC
connection name you created in the step B.
C. Iflow
In the iFlow, the Hana Server is connected via the Request Reply pallet. The connecting
adapter properties should mention the JDBC connection you created in the step B.
iFlow
In the iflow, In the JDBC Adapter properties - you mention the JDBC connection name you
defined in step B.
D. Execute the iflow in Postman
In the Postman, you pass the SQL statement in the body.
select * from sapabap1.sflight;
The output you will receive in xml format.
Postman
Pass the SQL Statement in body
This is how, we can establish the connectivity from CPI-iFlow to SAP Hana On premises and
execute the SQL Queries to fetch data.
The SQL output will be displayed in the xml format.
Conclusion