I always used U2U for checking my CAML queries in SharePoint. I have just used CAML Designer for SharePoint 2013 and it is brilliant.
Link to the CAML Designer tool
http://karinebosch.wordpress.com/2012/12/13/caml-designer-for-sharepoint-2013-released/
Simple Example of using CAML to query a list:
string riskListCAMLQry = "<Query><Where><Eq><FieldRef Name='Status' /><Value Type='Text'>Scheduled</Value></Eq></Where><View><RowLimit>1000</RowLimit></View></Query>"
Call using C# CSOM
CamlQuery camlQuery = new CamlQuery();
camlQuery.ViewXml = riskListCAMLQry; // Add a where clause on the status on the list to restrict the result set, only return the first 1000 rows
Link to the CAML Designer tool
http://karinebosch.wordpress.com/2012/12/13/caml-designer-for-sharepoint-2013-released/
Simple Example of using CAML to query a list:
string riskListCAMLQry = "<Query><Where><Eq><FieldRef Name='Status' /><Value Type='Text'>Scheduled</Value></Eq></Where><View><RowLimit>1000</RowLimit></View></Query>"
Call using C# CSOM
CamlQuery camlQuery = new CamlQuery();
camlQuery.ViewXml = riskListCAMLQry; // Add a where clause on the status on the list to restrict the result set, only return the first 1000 rows
No comments:
Post a Comment