Initializing the Query Object

There are two methods available for initializing the Query object.

Method

Description

initCubeQuery

Initializes the Query object for using multidimensional data. Requires that you provide one or more measures as parameters; dimensions are optional. If the dimensions parameter is null, then a default dimension layout that is based on the dimensionality of the measures is provided.

initQuery

Initializes the Query object for using relational data. Requires that you provide dimensions as parameters; measures are optional. If the measures parameter is null, then the resulting query will not contain data (as in a data body) but will be useful as a single dimension vector (for example, a vector of dimension value metadata).

Comparing Cube and Relational Data Access