cancel
Showing results for 
Search instead for 
Did you mean: 

how to consume OData service in sapui5

Former Member
0 Kudos

hi,

    how to consume Odata service  in sapui5 (table).

  If any idea  please share with me.

Accepted Solutions (0)

Answers (6)

Answers (6)

vishnucta
Active Participant
0 Kudos

Hi Amit,

The eror is because u are trying for cross domain request

Regards,

Vishnu

Former Member
0 Kudos

Hello Amit,

            actually i want to know how to create odata service using eclipse for sapui5?

vishnucta
Active Participant
0 Kudos

Hi Ripu,

Try installing the repositories for GWA in Eclipse and create a new project (OData Project).

Regards,

Vishnu

former_member232579
Discoverer
0 Kudos

Hi Amit,

This Problem could occur because the OData Service you want to access and your UI5 Application are in different domains.
You might want to have a look at this SAP/cloud-connectivityproxy · GitHub to solve this Issue.

Best Regards,

Ivo

Former Member
0 Kudos

thanks lvo for replaying . i shut out  problem..............

Former Member
0 Kudos

hey Amit,

I have got the same problem as yours, can u please explain me how did u slove the error..?

vijaybhaskarraju_vegesana
Active Participant
0 Kudos

Hi Amit,

Please have a look into below link,

Thanks,

Vijay V

Former Member
0 Kudos

Hi Amit - Please follow the link it might be useful to you.

Former Member
0 Kudos

i tryed but  some error comes:-

Failed to load resource: the server responded with a status of 401 (Unauthorized) https://xxxxxxxxxxxxxx.com/sap/opu/odata/sap/Z_BANK/$metadata


Failed to load resource: No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'http://localhost:55176' is therefore not allowed access.

sreehari_vpillai
Active Contributor
0 Kudos

Hi Amit, Are you able to execute the service URL from netweaver gateway client ? If yes OData is working fine. And where you are seeing the error reported ? In the browser ? Which browser you are using ? Regards Sreehari

Former Member
0 Kudos

crome  and ie both

thomas_jung
Developer Advocate
Developer Advocate
0 Kudos

I'm a little confused by your post.  You posted in the HANA development center, but from error message you appear to be using a NetWeaver Gateway service and not an XSODATA service as one might assume from the forum you choose to post within.  Are you in fact doing anything HANA specific here?

Perhaps a better overall description of what you are trying to do (with what technologies) would help. 

Jitendra_Kansal
Product and Topic Expert
Product and Topic Expert
0 Kudos

You can have a look at this blog

Virinchy
Active Contributor
0 Kudos

The SAPUI5 table control has  some sophisticated functions consuming ODATA for table design .

You might get quick and better responses if you can change the discussion from HanaDeveloperCenter to