Skip to Content

HANA XSOData registered to SEGW gives wrong data response

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.

Add a comment
10|10000 characters needed characters exceeded

  • 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

  • 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?

Related questions

1 Answer

  • Best Answer
    Posted on Nov 05, 2019 at 02:34 PM

    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.

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.