Discover(SystemDictionary: DalSystemDictionary; Filter: String): IDalCursor;
SystemDictionary. Cursor type to be obtained.
Filter. Filter applied to the cursor.
The Discover method returns the selected cursor type containing information about repository DBMS objects.
If the driver does not support the corresponding SystemDictionary, Null is returned.
To execute the example, add the Metabase and the Dal system assemblies to the unit.
Sub Main;
Var
Mb: IMetabase;
Connect: ISecurityConnection;
Cursor: IDalCursor;
CFields: IDalCursorFields;
CField: IDalCursorField;
i: Integer;
Begin
Mb := MetabaseClass.Active;
Connect := Mb.LogonSession.PrimaryConnection;
Cursor := Connect.Discover(DalSystemDictionary.Tables, "");
CFields := Cursor.Fields;
While Not Cursor.Eof Do
For i := 0 To CFields.Count - 1 Do
CField := CFields.Item(i);
Debug.WriteLine(CField.Name + " | " + CField.Value);
End For;
Cursor.Next;
End While;
End Sub Main;
After executing the example the console window displays system information about the tables stored in the current repository.
See also: