ICubeInstanceDestination.CreateExecutorO

Syntax

CreateExecutorO(Options: Integer): ICubeInstanceDestinationExecutor;

Parameters

Options. Cube calculation parameters.

Description

The CreateExecutorO method creates an object that calculates output cube matrix with the use of parameters.

Comments

As a value of the Options parameter, specify a value or a combination of values of the CubeInstanceDestinationExecutorOptions enumeration.

Example

Executing the example requires that the repository contains a cube with the CUBE identifier.

Add links to the Cubes, Dimensions, Matrix, Metabase system assemblies.

Sub UserProc;
Var
    MB: IMetabase;
    CubeInst: ICubeInstance;
    DefDest: ICubeInstanceDestination;
    SelSet: IDimSelectionSet;
    i: integer;
    DestExec: ICubeInstanceDestinationExecutor;
    Proxy: IMatrix;
    Iter: IMatrixIterator;
Begin
    MB := MetabaseClass.Active;
    CubeInst := MB.ItemById("CUBE").Open(NullAs ICubeInstance;
    DefDest := CubeInst.Destinations.DefaultDestination;
    SelSet := DefDest.CreateDimSelectionSet;
    For i := 0 To SelSet.Count - 1 Do
        SelSet.Item(i).SelectAll;
    End For;
    Debug.WriteLine("---------------Values-------------------");
    DestExec := DefDest.CreateExecutorO(CubeInstanceDestinationExecutorOptions.MatrixProxy);
    DestExec.PrepareExecute(SelSet);
    DestExec.PerformExecute(False);
    Proxy := DestExec.Matrix;
    Iter := Proxy.CreateIterator;
    Iter.Move(IteratorDirection.First);
    i := 0;
    While Iter.Valid Do
        Debug.WriteLine(i.ToString + " Iter.Value = " + Iter.Value);
        Iter.Move(IteratorDirection.Next);
        i := i + 1;
    End While;
End Sub UserProc;

After executing the example the ADOMD cube is calculated. The dimension selection for calculation is created as follows:

During calculation, fixed dimensions are excluded from the output matrix. Calculation results are displayed in the development environment console.

See also:

ICubeInstanceDestination