Skip to content

Aggregate Parameters Overview (OLAP)

JoeWinter edited this page Feb 19, 2015 · 2 revisions

[Table of Contents](https://github.com/dell-oss/Doradus/wiki/OLAP Databases: Table-of-Contents) | Previous | [Next](https://github.com/dell-oss/Doradus/wiki/Metric-Parameter for Aggregate Queries (OLAP))
OLAP Aggregate Queries: Aggregate Parameters Overview


Aggregate queries use the following parameters:
  • Metric (required): Defines one or more functions to calculate for selected objects. Metric functions such as COUNT, SUM, and MAX are supported. Each function is computed across selected objects, optionally subdivided into groups as defined by the grouping parameter. See the section Metric Parameter for details.

  • Query (optional): A DQL query expression that selects objects in the perspective table. When this parameter is omitted, all objects in the table are included in metric computations.

  • Grouping (optional): A list of one or more grouping expressions, which divide computations into single- or multi-level groups. When this parameter is omitted, the corresponding global query computes a single value for each metric function. When provided, the corresponding grouped query computes a value for each group value/metric function combination. A wide range of grouping expressions are supported as described in the section Grouping Parameter.

  • Pair (optional): A pair of field paths used to perform a special "pair query". See the section Pair Parameter for more details.

  • Shards (this or Range is required): Specifies a list of shards to search for objects by the query.

  • Range (this or Shards is required): Specifies a range of shards to search for object by the query.

  • XShards (optional): Specifies a list of shards to search for objects linked via xlinks. Either XShards or XRange can be specified, but not both. If neither is specified, xlink search scope defaults to Shards or Range parameter.

  • XRange (optional): Specifies a range of shards to search for objects linked via xlinks. Either XShards or XRange can be specified, but not both. If neither is specified, xlink search scope defaults to Shards or Range parameter.

How parameters are passed depends on the REST command. OLAP supports two commands for submitting aggregate queries:

  • URI command: All parameters are passed in the URI of the command.

  • Entity command: All parameters are passed in an entity (XML or JSON document) submitted with the command.

Details of each command are described in the section OLAP Aggregate Queries. In the examples used in this section, the URI command is used. The following sections describe the more complex parameters used by aggregate queries.

Clone this wiki locally