DynamicQueryable
DynamicQueryable copied to clipboard
Invalid Group expression usage
DynamicQueryable version
2.0.25
Steps to reproduce
https://gist.github.com/dcomartin/3e6fff415f6886c1b3c3b50b377fa0fc
Expected behavior
Should behave and return the same results as the linq statement.
Actual behavior
Throws a System.Exception: Invalid Group expression usage. This is from the Jokenizer which this package depends on.
Fixed with Jokenizer.Net 1.1.1 version.
Published new Nuget (2.0.25).
I think I'm still seeing this problem on 2.0.25. Might be something different but it's the same error. This is what I've got:
var where = "(FirstName.ToLower().Contains(@0) || FirstName.ToLower().Contains(@1)) && (LastName.ToLower().Contains(@0) || LastName.ToLower().Contains(@1))"
var searchTerms = new List<string> { "ron", "edwards" };
query = query.Where(where, searchTerms);
If I remove the parentheses around the ORs it works but then it doesn't filter correctly