SPSiteDataQuery - Describes a query performed across multiple lists, which may be located in multiple Web sites in the same Web site collection. You Can query multiple lists/Libraries of same kind for common fields in them. This Query returns a Datatable,which can be used as a source to GridView control etc.
In addition to this you can also Specify the List's to search in the scope! You need to provide the Guid of the List for that .
query.Lists = "<Lists><List Id="ListName">ListId</Lists> ";
Responses
0 Respones to "SPSiteDataQuery on Specific Lists in SharePoint"
Post a Comment