Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

CROSS ORIGIN ISSUE - Improper oData URL format

I am using proxy Servlet(attached below) and one handler(attached below) to resolve Cross origin issue.

Below is the code fragment I am using. But Its giving unexpected oData Url format due to which getting 404 error while reading the entity.

var loginId= sap.ui.getCore().byId("__xmlview0--loginId");

//its giving Entity set

var oModel = new sap.ui.model.odata.ODataModel("http://PO server:port num/MyApp/GWProxyServlet?sap/opu/odata/SAP/ZFK_ORD_HEADERDETAILS_SRV/");

//i am reading perticular entity"/EmployeeSet(empid='"+id+"')", null, null, false, function(oData){


// In console unexpected URL format as below

http://PO server:port num/MyApp/GWProxyServlet?EmployeeSet(empid='"+id+"'sap/opu/odata/SAP/ZFK_ORD_HEADERDETAILS_SRV/"

Please suggest on this.

Former Member
Not what you were looking for? View more on this topic or Ask a question