CHAPTER 14 LINQ to SharePoint and SPMetal

In previous versions of SharePoint, you could query lists and document libraries using Collaborative Application Markup Language (CAML). As an XML dialect, CAML syntax is relatively easy to pick up—you simply need to know which elements perform which functions, and then combine them to form a query. For example, a CAML query to return all items in a list named Products, where the product name begins with the letter A, might look something like this:

<Query>   <Where>       <BeginsWith>          <FieldRef Name='Title' />          <Value Type='Text'>A</Value>       </BeginsWith>    </Where> </Query>

The CAML syntax covers a number of standard functions, including logic operations such as AND and OR as well ...

Get Microsoft SharePoint 2010 Web Applications The Complete Reference now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.