Skip to Content
Technical Articles
Author's profile photo Gordon Witzel

SAP Cloud Platform Integration (CPI) to push data into SAP BW/4HANA

One option to connect cloud applications with other SAP and non-SAP cloud and on-premises applications is the usage of SAP Cloud Platform Integration (CPI).

SAP Cloud Platform Integration is using the new http (REST) based interface for data integration to SAP BW/4HANA 2.0.

This blog describes how to push data from a Cloud application into a SAP BW/4HANA advanced DataStore Object.

In the first step a BW persistency object must be created.

1.Create DataStore Object in SAP BW/4HANA 2.0

Open the BW Modeling Tools in Eclipse and create a new DataStore Object.

 

Maintain the technical name and the description.

Please use DataStore Object 0EPM_ADSO3 as an template otherwise the CPI integration flow will not work.

 

Maintain the Special Properties in the DataStore Object and set Write-Interface-Enabled. Activate the DataStore Object.

 

2. Install the SAP Cloud Connector

Please ensure that the SAP Cloud Connector is already installed and runs properly. Details are available here.

3. Maintain the Integration Flow 

Open SAP Cloud Platform Integration Web Interface (System dependent).

Open Operations View.

 

Open Security Material Tile.

Add new User Credentials to connect from CPI -> SAP BW/4HANA.

Add User Credentials and deploy.

 

Open Discover Page and search for Package SAP BW/4HANA Integration With Rest Based Data Load.

Open Artifact View of package SAP BW/4HANA Integration With Rest Based Data Load.

Configure Integration Flow Integration for Open Purchase Orders with Rest Based Data Load.

Maintain the Connection for the SAP BW/4HANA System to push data into the defined advanced DataStore Object (created in step 1 in that blog).

It is mandatory to maintain both reciever connections (BW4System and TokenService).

Start with Token Service and maintain the Adress -> BW Serverhostname and DataStore Object Name.

 

 

Open Receiver Connection BW4System and maintain Adress here as well -> BW Serverhostname and DataStore Object Name.

 

Save and deploy.

Open the Integration flow and check if the details are well maintained.

 

E.g. check the field mapping.

 

In 3 fields (EPM_CHAT, EPM_PDELD and EPM_POAS) SAP included a simple type conversion for date and boolean. Here is one example:

 

Once all settings and mappings checked and maintained – deploy the Integration Flow.

 

4. Consume the data in SAP BW/4HANA

Go back to the SAP BW/4HANA System and open the BW Modeling Tools in Eclipse.

Search for the Write-Interafce-Enabled  advanced DataStore Object in which the already created Integration Flow is pushing the data.

Open the Manage view in the context menu of the advanced DataStore Object.

 

You will now see all the already pushed data from the source to the advanced DataStore Object in SAP BW/4HANA.

 

It is now possible to create a virtual model (Composite Provider) or transfer the data to the next layer of your Enterprise data model depending on your data model and the Business requirements.

 

Assigned Tags

      27 Comments
      You must be Logged on to comment or reply to a post.
      Author's profile photo Peter Baumann
      Peter Baumann

      Hi Gordon,

      thank you very much for this interesting blog about new features. Am I right that what you show here is a specific demo scenario provided by SAP for this new interface?

      Could you also provide information about Cloud Integration before BW/4HANA 2.0 and maybe for other approaches or integrating from non-SAP Cloud systems for BW? I can't find much for this area...

      Author's profile photo Iñigo Montoya
      Iñigo Montoya

      Hi,

      In my last project I built an ABAP program running on BW (BW/4 actually), calling the a REST API from SCP Workflows. You don't have access to the tables directly.

      The steps are actually pretty much the same as in the CPI flow:

      • Create an REST Request using ABAP OO.
      • Get a Security Token.
      • Call the API to access the data, including the token in the request.
      • Write the data to a BW aDSO using the corresponding API (ABAP Function Module).
      • The rest should be easy as pie.

      The same approach would work with any DataSource exposed via a REST API.

      Using SCP CPI would be cleaner, but of course you have to change the first part of the flow, as you pointed out.

      You can search for blogs explaining how to extract data from SCP Workflows, actually.

      Iñigo

       

      Author's profile photo Thorsten Füg
      Thorsten Füg

      Hi Gordon,

      if I try to find the package "SAP BW/4HANA 2.0 Integration with Rest based Data Replication" on our CPI system I can't find it. Any idea?

       

      Regards
      Thorsten

      Author's profile photo Gordon Witzel
      Gordon Witzel
      Blog Post Author

      Hi Thorsten,

       

      the SAP BW/4HANA Integration With Rest Based Data Load API is now available - finally:

      https://api.sap.com/package/SAPBW4HANAIntegrationWithRestBasedDataLoad?section=Overview

      BR
      Gordon.

      Author's profile photo Lakshmi Narayana Nese
      Lakshmi Narayana Nese

      Thorsten,

      I can see the the:

      Integration for Open Purchase Orders with Rest Based Data Load

      Thnaks

      Lakshmi Nese

      Author's profile photo Brian Houston
      Brian Houston

      Has anyone done this with CPI-DS?  We do not have the web interface shown in this blog.

      Author's profile photo Gordon Witzel
      Gordon Witzel
      Blog Post Author

      Hi,

       

      the SAP BW/4HANA Integration With Rest Based Data Load API is now available - finally:

      https://api.sap.com/package/SAPBW4HANAIntegrationWithRestBasedDataLoad?section=Overview

      BR
      Gordon.

      Author's profile photo Shantharam Ramaswamy
      Shantharam Ramaswamy

      Hi,

      We used the same approach to update records into ADSO. When we tried to send an array of records from CPI, it fails. But works when we send only one record. Any insight on that will be helpful.  Thanks.

      Author's profile photo Regys Mene
      Regys Mene

      Hi Gordon,

      thanks for the great blog. As I see the add-on that you have configured in CPI-Side is only for BW4HANA. What about BW-on-HANA-System? Can the same logic be followed for a BW-on-HANA 7.5 System to integrate with CPI or something else should be done for that?

      Thank you,

      Regys

      Author's profile photo Gordon Witzel
      Gordon Witzel
      Blog Post Author

      Hi Regys,

      unfortunately not - the write interface enabled aDSO is exclusively available for SAP BW/4HANA.

      BR
      Gordon.

      Author's profile photo VENKATESH RAGOTHAMAN
      VENKATESH RAGOTHAMAN

      HI Gordon,

       

      Can i able to connect BW4HANA to ARIBA / IBP like this.

      Kindly guide me.

      Thanks for your support.

      Author's profile photo Antonio Maradiaga
      Antonio Maradiaga

      Hi VENKATESH RAGOTHAMAN ,

      This blog post 👉https://blogs.sap.com/2021/02/05/replicate-sap-ariba-operational-data-to-sap-bw-4hana-2.0/ contains details on how you can replicate data from SAP Ariba to BW/4HANA 2.0 using SAP Cloud Integration.

      Regards,

      .A

      Author's profile photo Sindhuja Jayapandiyan
      Sindhuja Jayapandiyan

      Hi Gordon,

      Can't we use the same approach for integrating to BW on HANA system. Kindly assist.

       

      Regards,

      Sindhuja.

      Author's profile photo Gordon Witzel
      Gordon Witzel
      Blog Post Author

      Hi Sindhuja,

       

      unfortunately not - the write interface enabled aDSO is exclusively available for SAP BW/4HANA.

      But in BW on Hana the WebService interface is available. You can use CPI and push data via the BW Webservice into SAP BW on Hana.

      BR
      Gordon.

      Author's profile photo Sindhuja Jayapandiyan
      Sindhuja Jayapandiyan

      Hi Gordon,

      Thanks for the response. So, can we use Soap adapter in CPI end to send data to BW on HANA system once webservice configuration done in BW on HANA end? Kindly provide an advice.

      Regards,

      Sindhuja.

      Author's profile photo Thorsten Stork
      Thorsten Stork

      Hello,

       

      how would it be possible to send data to multiple different DataSources as "one transaction" as it was possible via SAP PI/PO with ABAP Proxy interfaces ?

       

      Thank you

      Author's profile photo Jonathan Ma
      Jonathan Ma

      I understand that you need the cloud connector to make this work. But what configuration is needed for CPI to connect to the BW server?

      Author's profile photo Gordon Witzel
      Gordon Witzel
      Blog Post Author

      Hi,

      you can download the integration package here:

      https://api.sap.com/package/SAPBW4HANAIntegrationWithRestBasedDataLoad?section=Overview

      The feature is available since version SAP BW/4HANA 2.0.

      BR
      Gordon.

      Author's profile photo Jonathan Ma
      Jonathan Ma

      Thanks, Gordon

      I am aware of the package. I am trying to do a proof of concept using CPI to extract data from Ariba into BW/4Hana. I think I know how to configure the cloud connector now. Are you aware of any screenshots on configuring the CPI connection to the Ariba API? It seems to be very confusing since you have to download an access token.

      Author's profile photo Zubin Kurian
      Zubin Kurian

      Hi Gordon Witzel,

      Thank you for this useful blog. I have just one question about "Add new User Credentials to connect from CPI -> SAP BW/4HANA". Is there any documentation available about the type of BW user to provide (Dialog, System etc) and details about the BW Roles which this user should be given? We are attempting to implement this solution for productive use.

      Thanks in advance

       

       

      Author's profile photo Sasidhar Gunturu
      Sasidhar Gunturu

      Hi Gordon,

      Thank you for the article.

      Would also like to know if CPI can be integrated with SAP Datawarehouse Cloud for pushing the data using the REST APIs .

      Is this a possibility. Thank you very much for keeping us posted,

      Best Regards,

      Sasidhar

      Author's profile photo Henry Banks
      Henry Banks

      Hi Sasidhar Gunturu

      I'm not an expert in this space, but the online DWC Help documentation does reference using Open Connectors (part of Integration Suite) to connect to API providers:

      https://help.sap.com/viewer/9f804b8efa8043539289f42f372c4862/cloud/en-US/9bfe7db51216449d985a0b59f5e181c4.html

      Regards, H

      Author's profile photo Sasidhar Gunturu
      Sasidhar Gunturu

      Hi Henry,

      Could you be able to share the architecture details  for CPI to SAP DWC for real time data extraction /reporting ,

       

      Best Regards,

      Sasidhar

      Author's profile photo Gordon Witzel
      Gordon Witzel
      Blog Post Author

      Hi Sasidhar,

      as Henry already mentioned,  SAP Open Connectors (part of Integration Suite) are the recommended way to connect to API providers:

      https://help.sap.com/viewer/9f804b8efa8043539289f42f372c4862/cloud/en-US/9bfe7db51216449d985a0b59f5e181c4.html

      BR

      Gordon.

      Author's profile photo Jonathan Black
      Jonathan Black

      Hi Gordon,

      I'm trying to set this up. I've cloned the template package in CPI and changed it to point to our specific data store object but I get a 403 when trying to fetch the token. Do we need to activate any services in BW/4 - SICF?

      Cheers

      Jon

      Author's profile photo Former Member
      Former Member

      Hi Gurus,

      Is there a way to integrate Kronos to BW4HANA2.0 with a pull mechanism? As this is a pull connection, we cannot leverage the write interface ADSO option? Kindly suggest.

      Is ODP HTTPS source system an option?

      If somebody has experience with this kind of connection, please share steps for the same

      Thanks & Regards,

      Venka Reddy

      Author's profile photo Frank Riesner
      Frank Riesner

      Hi Venka,
      there seems to be an integration on ERP side of Kronos with SAP HCM or SAP SuccessFactors.
      https://api.sap.com/package/SuccessFactorsEmployeeCentralwithThirdPartyTimeVendorKronos/overview

      Then the integrated HR data can be integrated based on SAP standard interfaces as described here.

      As Kronos is it cloud-based, it is probably not possible to directly connect to its DB and you have to rely on its APIs. So maybe SAP Data Intelligence is be able to pick Kronos data (see connectors here) to deliver it to BW.

      KR Frank