Cubes(Cube: String): IDalCursor;
Cubes(Cube: String): Prognoz.Platform.Interop.Dal.IDalCursor;
Cube. Physical name of the cube.
The Cubes method returns the cursor, that contains system information about the cube with specified name.
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.
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(Null) As 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.
Executing the example requires that the repository contains an ADOMD catalog with the ADOMDTest identifier. This example is an entry point of the .NET assembly.
Imports Prognoz.Platform.Interop.AdoMd;
Imports Prognoz.Platform.Interop.Dal;
Imports Prognoz.Platform.Interop.Metabase;
Public Shared Sub Main(Params: StartParams);
Var
MB: IMetabase;
Catalog: IAdoMdCatalogInstance;
Connection: IAdoMdConnection;
Cubes: IDalCursor;
CFields: IDalCursorFields;
CField: IDalCursorField;
i: Integer;
Begin
MB := Params.Metabase;
Catalog := MB.ItemById["ADOMDTest"].Open(Null) As 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];
System.Diagnostics.Debug.WriteLine(CField.Name + " | " + CField.Value);
End For;
Cubes.Next();
End While;
End Sub;
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: