.includes() should translate to "contains", not "substringof" (OData4)
TheoBP opened this issue · 3 comments
TheoBP commented
E.g. filters such as:
.where(b => b.Title.includes("C# 7.0"))
Currently generates:
https://www.solenya.org/odata/Books?$expand=AuthorBooks(%24expand%3DAuthor)&$orderby=Title&$filter=substringof(%22Essential%22%2C%20Title)
But should generate:
https://www.solenya.org/odata/Books?$expand=AuthorBooks(%24expand%3DAuthor)&$orderby=Title&$filter=contains(Title,%27Essential%27)
umutozel commented
I believe this is also a version issue, this is a good time to drop support for older OData versions. I will switch to contains soon. I always found substringof
unintuitive anyway :)
TheoBP commented
Totally agree :)
umutozel commented
Done. alpha.7 package published.