SharePoint Multi-Record Data Provider

SharePoint Multi-Record Data Provider

General Info

This Data Provider is used to fetch multiple list items from a SharePoint custom list or document library. The result value is an array of objects
The properties used to configure this provider are the following:
  1. Url: The url of the SharePoint site where the list/document library belongs. Leave blank in order to use the current one.
  2. List: The SharePoint list/document library name (selection from a dropdown)
  3. Fields: Multi-select list of column names that will be fetched. If empty, the list's default view columns will be returned
  4. Field for control search: applicable when this kind of provider is used for obtaining Lookup Values for a Combobox control. It is used for extra filtering according to the search term that is specified by the user within the combobox, as shown below:

The operator for this kind of search is always "Contains" (Search any part of the text). 
This functionality is particularly useful on large lists where the provider would return thousands of records, in order to perform filtering of the items on the server through a SharePoint/CAML query. This logic prevents the unorthodox process of fetching all the records from the server first, and then applying the filters on the client side, which could cause huge performance issues.
Make sure you watch out for conflicts between this setting and the "Client Filter Results" property of the Combobox, which filters data on the client based on the Lookup Display Field property. You may find list items disappearing from the dropdown if the criteria columns are different between the Provider and the Combobox. It is recommended that you disable the Client Filter Results property when you use the "Field for control Search
  1. Sort Order Field: The column per which to order results.
  2. Sort Ascending: Choose whether the sorting will be done in ascending/descending order.
  3. Row Limit: Limits the number of results. If left blank, value 0 is implied, which means no limit. 
  4. Criteria: You can add, remove and re-order filters using the list editor on the bottom of the page. Each filter has the following attributes:
a) Field Name: The internal name of the column
b) Field Value: The value to filter. 
You can use a formula/expression for values that need to be evaluated during runtime. In order to do that, make sure that the value is preceded with an equals (=) sign, for example:
=form.GetControl("Title").GetValue()
c) Operator: The Search Operator to be used, in accordance with the SharePoint CAML Comparison Operators (Equals, NotEquals, Contains, Greater, GreaterOrEqual, Less, LessOrEqual, IsNull)
d) Type: The Filter Data Type, in accordance with the SharePoint CAML Value Types (Text, DateTime, Number, Lookup).
For filters of type "Lookup", the ID of the lookup item should be used as a value.
e) Ignore Blank: If this option is enabled and the field value is null (or evaluated as null at runtime), then this filter is completely removed (ignored) from the criteria set. Useful for implementing "return all if not specified" logic in your searches. 

This is how a typical configuration of a SharePoint Multi-Record Provider looks like:


See Also

For more info about the concept of Data Providers, their usage and their common properties (Name, OnDataLoaded, Condition, etc) see Basic Concepts: Intro to Data Providers