I know how to query if the condition is GivenName = 'a' or SurName = 'a'.
But how can I query users by condition GivenName = 'a' or GivenName = 'b'? UserQuery can only set one Criterion on one property, currently I have to query many times then add them together. If I can query only one time, it save lot of time.
Does anybody have idea?
I think you should be able to use the StringInCriterion, something like:
var uq = new UserQuery();uq.GivenName = new StringInCriterion();uq.GivenName.Values.Add("a");uq.GivenName.Values.Add("b");I haven't tried this and I might not remember correctly how to use it. But something like it may work.
Hi Magnus, thanks for you answer
What should be used is "Includes"
uq.GivenName.Includes = new StringInCriterion();uq.GivenName.Includes.Values.Add("a");uq.GivenName.Includes.Values.Add("b");
Ah, yes of course, I forgot that level. I suppose it would have been obvious if I had actually tried to assign it :)