Product Information
How to setup Model View OData
As such, one of the most sought after feature is a function which has the ability to consume and read data from external OData. With the use of OData endpoint or what appears to be a URL containing lots of information, data extraction have been made easy with the introduction of Model View OData.
The same as with the existing Model Functions which consume data from external table, Model View Odata can easily be set up in Modeling Screen just like how Model View HANA Table/View is configured. As an overview of the steps 1) Create a Connection, 2) Fill in the needed information, 3) Use the connection created connection then map the source fields, 4) Save, Activate and Show then voilà, data are now available in SAP PaPM Cloud Environment.
In the case of Model View OData, there are pre configurations which need to be done prior to the execution of the above numbered steps. So in this blogpost, I will give you the step-by-step guide on how to consume data from an external Odata such as SAP Analytics Cloud (SAC) Model.
- An external OData should be available for consumption such as SAC Model or any opensource OData service like Northwind. Below is an example of a Model in SAC.
- In order to establish connection between the SAP PaPM Cloud Subaccount and SAC through creating Destination in SAP Business Technology Platform (BTP), get OAuth Client Credentials in SAC as well as the Token URL.
2a. In SAC, go to System -> Administration -> App Integration Tab
2b. In the list of available Configured Clients, hover over one configured client -> Choose Edit OAuth Client then get the Client ID and Client Secret. Otherwise, with proper authorization, you can Set Up the OAuth Client by yourself.
- Go to SAP BTP and choose the subaccount where you want to test the integration.
3a. Choose Destination and choose New Destination.
3b. Fill in the following info then save changes.Field Values Destination Name Unique name of destination in current subaccount. Type HTTP Description Any description for Destination Name URL URL of SAC excluding entries from /sap/fpa…. onwards Proxy Type Internet Authentication Oauth2ClientCredentials Client ID Get information from Configured Clients on step 2b
Client Secret Get information from Configured Clients on step 2b Token Service URL Type Dedicated Token Service URL Get information from Application Integration Tab on step 2b Additional Properties Choose New property then input below default values: request headers {“x-sap-sac-custom-auth”:”true”} Mark Check – Use default JDK trust store.
- Go to the Connection Management in PaPM Cloud Application and Create OData Connection pointing to your model in SAC. Fill in with the following information:
Field Values Destination Name name of the created destination from BTP Entity Set Name refers to the section of OData where the data to be consumed resides e.g. FactData Service Root additional path options. In case of SAC, it will point to SAC Model /api/v1/dataexport/providers/sac/<SAC Model ID>
see Note in Step 1
e.g. /api/v1/dataexport/providers/sac/CPPJAP1CH9L6I8QMXKXWFS3K0Maximum Page Size specifies the maximum number of entities returned per page of OData results e.g. 10000. If nothing is maintained, by default this will be set to 1000. - Create Model Table OData in Modeling Screen. Fill in the information of created connection in the properties panel. Choose Edit Fields in order to map the fields. Activate the function then choose Run. Show results.
SAP Analytics Cloud Model data is now available in SAP PaPM Cloud through Model View OData Function. I hope you that you’ve picked up a thing or two which can be helpful in your data export battles.
In case you want to know how to SAC consume data in SAP PaPM Cloud visit my new blogpost: How SAP Analytics Cloud (SAC) pulls data from SAP Profitability and Performance Management Cloud (SAP PaPM Cloud)
Stay tuned for future updates about new features to be released! Cheers!
Hi Paul
This is great. I have few questions
Hi,
Great post! It worked for me.
I will add the following case that could be useful:
In our BTP cockpit destination the property "request headers" wasn't on the options so I just wrote it manually, all good no errors, but the connection wasn't working. After a few tests, I just left that property blank and it worked.
I just left it blank the following:
Additional properties
Hope it helps.
Regards
Hi Edwin Romero ,
The additional parameter syntax is requestHeaders since you can't enter any blank in any of the additional property. Please have a look at the screenshot of the destination in the blog.
Thanks
Arvind Sharma