Session login with proxy user
Session login with proxy user
Hi,
I have ODAC 6.9 VCL
I need to login to oracle as a proxy user. Like this: User[XX]
Does ODAC support this?
If so can anyone give me an example code.
Reg,
Arni Thor
I have ODAC 6.9 VCL
I need to login to oracle as a proxy user. Like this: User[XX]
Does ODAC support this?
If so can anyone give me an example code.
Reg,
Arni Thor
var
OraSession1,
OraSession2: TOraSession;
begin
Orasession1 := TOraSession.create(self);
Orasession1.Username := 'myuser';
Orasession1.Password := 'mypassword';
Orasession1.Server := 'myhost';
Orasession1.Connect;
OraSession2 := TOraSession.create(self);
OraSession2.Server := OraSession1.Server;
OraSession2.Username := 'more_priv_user';
OraSession2.Connect;
end;
This does not work....
Can you please help me
I have a proxy user on my db. and can connect with username like this MYUSER[MASTER] / Password
with Oracle SQL Developer and SQL Nav 6.2
OraSession1,
OraSession2: TOraSession;
begin
Orasession1 := TOraSession.create(self);
Orasession1.Username := 'myuser';
Orasession1.Password := 'mypassword';
Orasession1.Server := 'myhost';
Orasession1.Connect;
OraSession2 := TOraSession.create(self);
OraSession2.Server := OraSession1.Server;
OraSession2.Username := 'more_priv_user';
OraSession2.Connect;
end;
This does not work....
Can you please help me
I have a proxy user on my db. and can connect with username like this MYUSER[MASTER] / Password
with Oracle SQL Developer and SQL Nav 6.2
The user was created correctly.
This works now
Orasession1 := TOraSession.create(self);
Orasession1.Username := 'MyUser';
Orasession1.Password := 'MyPassword';
Orasession1.Server := 'MyServer';
Orasession1.Connect;
OraSession2 := TOraSession.create(self);
OraSession2.Server := OraSession1.Server;
OraSession2.ProxySession := OraSession1;
OraSession2.UserName := 'MasterUser';
OraSession2.Connect;
OraSQL := TOraSQL.Create(self);
OraSQL.Session := Orasession2;
OraSQL.SQL.text := 'select * from table';
OraSQL.Execute;
Case closed, thanks
This works now
Orasession1 := TOraSession.create(self);
Orasession1.Username := 'MyUser';
Orasession1.Password := 'MyPassword';
Orasession1.Server := 'MyServer';
Orasession1.Connect;
OraSession2 := TOraSession.create(self);
OraSession2.Server := OraSession1.Server;
OraSession2.ProxySession := OraSession1;
OraSession2.UserName := 'MasterUser';
OraSession2.Connect;
OraSQL := TOraSQL.Create(self);
OraSQL.Session := Orasession2;
OraSQL.SQL.text := 'select * from table';
OraSQL.Execute;
Case closed, thanks