Database: String;
Database: String;
Свойство Database определяет наименование базы данных, в которой хранятся данные репозитория.
Добавьте ссылку на системную сборку Metabase.
Sub UserProc;
Var
MbMan: IMetabaseManager;
MbDefs: IMetabaseDefinitions;
MbDef: IMetabaseDefinition;
VertSPLD: IPrimaryVerticaSPLD;
Begin
MbMan := MetabaseManagerFactory.Active;
MbDefs := MbMan.Definitions;
MbDef := MbDefs.Add;
MbDef.DriverId := "VERTICA";
MbDef.Id := "VERTICA";
MbDef.Name := "VERTICA";
MbDef.Authentication := AuthenticationMode.Password;
MbDef.SecurityPackage := "STANDARDSECURITYPACKAGE";
VertSPLD := MbDef.LogonData As IPrimaryVerticaSPLD;
VertSPLD.Server := "VERT_SRV";
VertSPLD.Database := "VERTICA";
VertSPLD.Scheme := "USERS";
VertSPLD.Port := "5433";
MbDef.Save;
End Sub UserProc;
Imports Prognoz.Platform.Interop.Metabase;
Public Shared Sub Main(Params: StartParams);
Var
MbManagerCls: MetabaseManagerFactory = New MetabaseManagerFactoryClass();
MbMan: IMetabaseManager;
MbDefs: IMetabaseDefinitions;
MbDef: IMetabaseDefinition;
VertSPLD: IPrimaryVerticaSPLD;
Begin
MbMan := MbManagerCls.Active;
MbDefs := MbMan.Definitions;
MbDef := MbDefs.Add();
MbDef.DriverId := "VERTICA";
MbDef.Id := "VERTICA";
MbDef.Name := "VERTICA";
MbDef.Authentication := AuthenticationMode.amPassword;
MbDef.SecurityPackage := "STANDARDSECURITYPACKAGE";
VertSPLD := MbDef.LogonData As IPrimaryVerticaSPLD;
VertSPLD.Server := "VERT_SRV";
VertSPLD.Database := "VERTICA";
VertSPLD.Scheme := "USERS";
VertSPLD.Port := "5433";
MbDef.Save();
End Sub;
После выполнения примера будет создано новое описание репозитория.
См. также: