I have this SQL query and it works perfectly. However, when I try to create a similar CAML it doesn't work. Is there a tool that can convert SQL to CAML. or can someone please help. Here is the SQLFiddle. http://sqlfiddle.com/#!18/0557ef/10
select assignedto
from sample_approvers_list
where
libraryname='packaging' and level='a' and LineName = 'pure'
or
(libraryname='packaging' and level='a' and AnyLine='Yes')
<Where>
<And>
<Eq>
<FieldRef Name='Library' />
<Value Type='Lookup'>Packaging</Value>
</Eq>
<And>
<Eq>
<FieldRef Name='Level' />
<Value Type='Choice'>A</Value>
</Eq>
<Or>
<Eq>
<FieldRef Name='LineName' />
<Value Type='Lookup'>PURE</Value>
</Eq>
<And>
<Eq>
<FieldRef Name='AnyLine' />
<Value Type='Boolean'>1</Value>
</Eq>
<Eq>
<FieldRef Name='AnyPlace' />
<Value Type='Boolean'>1</Value>
</Eq>
</And>
</Or>
</And>
</And>
</Where>