Skip to Content
avatar image
Former Member

Filters and select system query in xsodata service SAPUI5

Hi experts,

currently i am facing issues with my xsodata service. It is created based on HANA calculation view. It has one collection with about 40 properties. I want to use filters and the select system query.

        var aFilter = [new sap.ui.model.Filter("YEAR", "EQ", "2016"),
                       new sap.ui.model.Filter("MONTH", "EQ", "12")];
        oModelBstVertraege.read("/Collection", {
            "urlParameters": {"$select": "YEAR,MONTH"},
            "filters": aFilter,
            "success": (oData, response) => {
                console.log(oData);
                }
        });

I expected this code snippet to just return the entries for the properties YEAR and MONTH where YEAR equals 2016 and MONTH equals 12. I expect about 7500 entries but only receive one. also when i comment out the "filters" I only receive one entry.

Has anybody suggestions?

Thanks

Add comment
10|10000 characters needed characters exceeded

  • Former Member

    Filtering works fine. The select system query is not implemented correctly I guess.
    Thanks for your comments so far - I will update you when I find a solution.

    Regards

  • Former Member

    By now i think the service works as it should be. It is the logic of the calculation view the service is based on. The result is an OData service which works different than the OData specification tells.

  • Hi Benjamin Schmitz,

    Could you check if you have implemented filter in your OData back-end.

    Regards,

    Arjun Biswas.

  • Get RSS Feed

0 Answers