Proxy user in Direct mode
Posted: Wed 22 Oct 2014 11:36
Hi,
I am trying to use the following code to connect to Oracle DB in Direct Mode but in second session Connect I cannot. OCI_INVALID_HANDLE exception. Please help
Thank you,
Orasession1 := TOraSession.create(self);
Orasession1.Options.Direct := true;
Orasession1.Username := 'ORA_PROXY';
Orasession1.Password := 'P@55w0rd';
Orasession1.Server := 'lnx-dbdev:1522:sid=oradb';
Orasession1.Connect;
OraSession2 := TOraSession.create(self);
OraSession2.Server := OraSession1.Server;
OraSession2.ProxySession := OraSession1;
OraSession2.UserName := 'ORA_ADMINISTRATOR';
OraSession2.Connect;
I am trying to use the following code to connect to Oracle DB in Direct Mode but in second session Connect I cannot. OCI_INVALID_HANDLE exception. Please help
Thank you,
Orasession1 := TOraSession.create(self);
Orasession1.Options.Direct := true;
Orasession1.Username := 'ORA_PROXY';
Orasession1.Password := 'P@55w0rd';
Orasession1.Server := 'lnx-dbdev:1522:sid=oradb';
Orasession1.Connect;
OraSession2 := TOraSession.create(self);
OraSession2.Server := OraSession1.Server;
OraSession2.ProxySession := OraSession1;
OraSession2.UserName := 'ORA_ADMINISTRATOR';
OraSession2.Connect;