Skip to Content
author's profile photo Former Member
Former Member

Filter in table SAPUI5 with XML view

Dear all,

I have an XML view where a table should be displayed but not with all the data from oData. So, I want to create a filter in the onInit function of the controller to display only the rows which contains with the given value.

This is my XML view:

This is my onInit code:

Now, all the data is displayed in the table without the filter.

Can someone give me a solution or an example to set a filter on the table in the onInit function of the controller?

Thanks in advance!

Kind regards,


Capture.PNG (9.9 kB)
Capture.PNG (34.9 kB)
Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

1 Answer

  • Posted on Feb 02, 2016 at 01:28 PM

    Could you please check this example code SAPUI5 Explored

    and JS Bin - Collaborative JavaScript Debugging


    <table:Table rows="{

    path: '/table',

    filters: [{

    path: 'field3',

    operator: 'EQ',

    value1: 'test'


    sorter: [{

    path: 'field1',

    descending: false

    }, {

    path: 'field2',

    descending: true





    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.