I'm trying to query a list and get newsletter articles back that match the list of active newsletters.
The trouble comes in when trying to pull items via CAML. If I do an OR loop with two CONTAINS, it works great. For example:
<Where>
<Or>
<Contains>
<FieldRef Name=\"Newsletter_x0020_Name\"/>
<Value Type=\"Lookup\">April 2012</Value>
</Contains>
<Contains>
<FieldRef Name=\"Newsletter_x0020_Name\"/>
<Value Type=\"Lookup\">May 2012</Value>
</Contains>
</Or>
</Where>
Works great!
Add in a third line and we have trouble:
<Where>
<Or>
<Contains>
<FieldRef Name=\"Newsletter_x0020_Name\"/>
<Value Type=\"Lookup\">April 2012</Value>
</Contains>
<Contains>
<FieldRef Name=\"Newsletter_x0020_Name\"/>
<Value Type=\"Lookup\">May 2012</Value>
</Contains>
<Contains>
<FieldRef Name=\"Newsletter_x0020_Name\"/>
<Value Type=\"Lookup\">June 2012</Value>
</Contains>
</Or>
</Where>
I've made sure it wasn't the parameters inside the name column (Meaning I've tried every combination possible of April, May and June in both the two Parameter and three Parameter implementations) and nothing changes. I can use any set of parameters, and two columns always works, and three always fails.
Help?