cancel
Showing results for 
Search instead for 
Did you mean: 

HANA XSOData registered to SEGW gives wrong data response

0 Kudos

So we have a requirement to use a HANA XS Odata service for a Fiori app, we have created an alias on the gateway to HANA system and registered the Xs Odata service using SEGW. The service shows successfully registered with no errors, but when we make a request to the registered service it returns incorrect data. For example, if I request '?select=Plant,Status,Count' we should see a result that gives each plant, the status and an overall count of that status. But instead the structure of the data is broken, it will only give count as 1, and list the same plant over and over. The original service still works fine on HANA, but registering it to the gateway has caused it to not work correctly. I have searched all over for the error and possible solution with no luck. Is this an error anyone else has encountered when registering XSOdata to the gateway via system alias? It seems like the relationships of the data properties are no longer connected. The service will no longer aggregate the values, so even simple queries will return the same line item repeating hundreds of times, when it should be only listing each plant a single time.

Edit: I have also tried to use reverse proxy connection through web dispatcher, but not sure exactly how to configure it properly to use as a service in our Fiori app.

gregorw
Active Contributor

Don't think that ?show=Plant,Status,Count is a valid OData request parameter. So might it be that your HANA Backend Service is a custom build xsjs endpoint? Have you used the HTTP Client recording functionality of transaction SICF to see what request is done from SAP Gateway to the HANA backend? What is used for authenticaiton to the HANA backend?

0 Kudos

Hi, thanks for the response. I did not create the xs Odata service, I think it could be a custom xsjs endpoint. My mistake, I meant 'select', instead of show - so the request '?$select=Plant,Status,Count' does work on the original xs odata service.There is no authentication on the service. I have not looked into the client recording functionality of SICF to see what request is being made to HANA. Is there by any chance a guide you can share on how to record using SICF to investigate the issue? Thank you for the tip

View Entire Topic
0 Kudos

We did finally figure out this issue, for anyone who has a similar problem. Basis and DBA team configured web dispatcher to connect to the HANA system. But there was some CORS problem that persisted. So we had to go and edit the xs admin console and modify the allowed headers, as shown in this article: https://answers.sap.com/questions/65623/cors-issue-accessing-xsodata.html

But now we are able to connect with the app so the issue is no longer there.