I'm performing a query as follows:
StringCriterion sCrit = new StringCriterion();sCrit.Value = myValue;clubQuery["MyCustomAttribute"] = sCrit;
for a field that I've added. This works perfectly, however, there are cases where I want to specify several possible values for MyCustomAttribute.
I know you can use CriteriaGroup for several different fields, but how do I do it for the same attribute?
The result I want is "MyCustomAttribute IN ('X', 'Y', 'Z')".
If anyone could lend me a hand here I'd much appreciate it.
Instead of setting sCrit.Value you should be able to set sCrit.Inclues = new StringInCriterion() and then add the values you want to search for in that.
Lovely, just what I was looking for. I owe you my life :)