Skip to Content

sap.ui.model.odata.v2 OperationMode = Client Not working

Jul 20, 2017 at 10:47 AM


avatar image
Former Member

Hi All

I have created a simple master detail UI5 app with a single Model.

I set the operation mode to Client in the manifest for the UI5 app.

I then expect the app to behave in the following way:

1. When the app is opened an oData call is made to the server to get the data for the master List.

2. When I then search the Master List using the search input I don't expect any further odata calls as I have set the default OperationMode of the Model to Client.

But I am getting oData calls to the server every time I search the list.

The definition of OperationMode = Client is below:

"Operations are executed on the client, all entries must be available to be able to do so. The initial request fetches the complete collection, filtering and sorting does not trigger further requests."

I can see my initial call loads all the data required and I use an inline count.

Am I missing something?

Has anyone else been able to use a default OperationMode = Client on a Master Detail app.

Any ideas/thoughts greatly appreciated.

Am going to try debugging to see what is going on :-)



upirm.png (15.1 kB)
10 |10000 characters needed characters left characters exceeded
* Please Login or Register to Answer, Follow or Comment.

1 Answer

Best Answer
saurabh vakil Jul 20, 2017 at 11:08 AM

Hello Andrew,

I have tried building an app in Web IDE using the master detail template and set the Operation Mode as Client, Binding Mode as TwoWay and Count Mode as Inline. With these settings when I do a search in the master list I do not see any network call being triggered in the Network tab of the developer console and I see the search result returned successfully.



Show 2 Share
10 |10000 characters needed characters left characters exceeded
Former Member

Hi Saurabh

Thanks you put me on the right track.

So this is what I found.

The app I created was imported from BUILD, and it created code that used the following for search input.

oControl.bindAggregation("items", {
		path: oBindingInfo.path,
		template: oBindingInfo.template,
		sorter: oBindingOptions.sorters,
		filters: oBindingOptions.filters 

I then created a new app using the template like you suggested and it uses the following code for search input.

oControl.getBinding("items").filter(aFilters, "Application");

So I moved the code for searching from the template app into my BUILD app and now it works!!!!

So it must be something relating to using the bindAggregation method that was added by BUILD.




Thanks for letting us know exactly how you have overcome the issue!