How to use “contains” or “like” in a dynamic linq query?

Here is the answer! The Dynamic Linq does support the . operator,

According to the docs:

“Instance field or instance property
access. Any public field or property
can be accessed.”

Thus, it is possible to use this syntax

.Where("MyColumn.Contains(@0)", myArray)

Thanks for all the suggestions! And thanks to me for finding the solution.

Leave a Comment