Skip to content

Release 2.10.0

Compare
Choose a tag to compare
@andrei-markeev andrei-markeev released this 10 Jun 10:36
· 33 commits to master since this release

Added support for Aggregations and GroupLimit attribute in GroupBy clause.

Example:

var query = new CamlBuilder()
    .View([
        "ID",
        { count: "Country" },
        { avg: "FlightCost" }
    ])
    .Query()
    .GroupBy("Country", true, 100)
    .ToString()

results in the following CAML:

<View>
    <ViewFields>
        <FieldRef Name="ID" />
    </ViewFields>
    <Aggregations Value="On">
        <FieldRef Name="Country" Type="COUNT" />
        <FieldRef Name="FlightCost" Type="AVG" />
    </Aggregations>
    <Query>
        <GroupBy Collapse="TRUE" GroupLimit="100">
            <FieldRef Name="Country" />
        </GroupBy>
    </Query>
</View>

Note: Aggregations should be used with RenderListData endpoint.