Skip to Content
avatar image
Former Member

SAPUI5 (ODataMetadata) initial loading of metadata failed while using OData service

Hi!

I have problem while using OData service with sapui in Data binding.

Fisrt i Created destination in SAP CLOUD PLATFORM COCKPIT for below details

Maniest.json

	"dataSources":{
			"ES5":{
				"uri":
		     "destinations/ES5/sap/opu/odata/IWBEP/GWSAMPLE_BASIC/",
				"type":"OData",
				"settings":{
					"odataVersion":"2.0"
				}
			}
		}
----------------------

	"Model":{
				"dataSource":"ES5"
			}

neo-app.json

{
    "path":"/destinations/ES5",
    "target":{
    	"type":"destination",
    	"name":"ES5"
    },
    "description":"ES5 DEMO SYSTEM"
    }

Controller.js

onInit: function(){
		   	var oForm = this.getView().byId("idsf");
		   	oForm.bindElement("Model>/ProductSet('HT-1030')");
		   }

View.xml

	<f:SimpleForm editable="true" 
                      id = "idsf" 
                      layout="ResponsiveGridLayout" 
                      title = "Products">
		<f:content>
		    <Label text = "ProductID"/>
		     <Input value = "{Model>ProductID}"/>
		</f:content>
	</f:SimpleForm>

In browser network panel I see, that metadata loaded incorrect,

plz solve the isuue.

destinations.png (22.2 kB)
Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

2 Answers

  • avatar image
    Former Member
    Feb 22 at 01:05 PM

    Use the chrome developer tools and check if metadata is being returned, if it can not be an error in the version of odata or incomplete metadata, and so on.

    Add comment
    10|10000 characters needed characters exceeded

  • Feb 22 at 04:56 AM

    Set the Authentication type to No Authentication and give a shot

    I was working with ES4 it was working fine

    Add comment
    10|10000 characters needed characters exceeded