IAdoMdConnection.Cubes

Syntax

Cubes(Cube: String): IDalCursor;

Parameters

Cube. Physical name of the cube.

Description

The Cubes method returns the cursor, that contains system information about the cube with specified name.

Comments

The obtained cursor contains the information about all the cubes contained in the ADOMD catalog if the Cube parameter is not specified. A specific record is added to the cursor to divide information by cubes. First field in this record has no name and the cube number is used as the field value.

Example

Executing the example requires that the repository contains an ADOMD catalog with the ADOMDTest identifier.

Sub UserProc;
Var
    MB: IMetabase;
    Catalog: IAdoMdCatalogInstance;
    Connection: IAdoMdConnection;
    Cubes: IDalCursor;
    CFields: IDalCursorFields;
    CField: IDalCursorField;
    i: Integer;
Begin
    MB := MetabaseClass.Active;
    Catalog := MB.ItemById("ADOMDTest").Open(NullAs IAdoMdCatalogInstance;
    Connection := Catalog.Connection;
    Cubes := Connection.Cubes("");
    CFields := Cubes.Fields;
    While Not Cubes.Eof Do
        For i := 0 To CFields.Count - 1 Do
            CField := CFields.Item(i);
            Debug.WriteLine(CField.Name + " | " + CField.Value);
        End For;
        Cubes.Next;
    End While;
End Sub UserProc;

The cursor, containing the information about all the cubes, contained in the ADOMD catalog, is obtained when executing an example. This information is displayed in the development environment console.

See also:

IAdoMdConnection