Retrieving Items from a SharePoint List with subfolders using CAML Filtering

When you run a CAML query to retrieve items from a SharePoint list, make sure that your CAML query tag does not include the <Query></Query> tags.  When you include this tag, the filters are disregarded and you will retrieve the entire list
A caml query like this
<FieldRef Name=’Title’>
<Value Type=’Text>Title.xml</Value>
Will not retrieve the list item.
Remove the <Query></Query> tags and you should be able to retrieve the results according to the filter specified.
Here is a sample


Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

%d bloggers like this: