Oracle wallet and ODAC

Discussion of open issues, suggestions and bugs regarding ODAC (Oracle Data Access Components) for Delphi, C++Builder, Lazarus (and FPC)
Post Reply
alexllerrac
Posts: 2
Joined: Wed 28 Dec 2016 11:10

Oracle wallet and ODAC

Post by alexllerrac » Wed 28 Dec 2016 11:20

Hello all.

Has anyone used Oracle wallet. Standard wallet set up, I understand.
Works fine with ADO.

I simply connect with /@server and receive:
[Window Title]
Error

[Content]
Access violation at address 00000000. Read of address 00000000

[OK]

I ask now, before I link this up to Eureka log and see if its in the source. I would have hoped it would work out the box.
I have spent quite a bit of time searching and seen no code examples, so I am getting the feeling that wallet is not properly supported.

hoping for some inspiration,
Alex

alexllerrac
Posts: 2
Joined: Wed 28 Dec 2016 11:10

Re: Oracle wallet and ODAC

Post by alexllerrac » Fri 30 Dec 2016 06:37

Hi,
Just in case.
1) ODAC works perfectly with wallet, no issues. Follow Oracle instructions for creating a wallet, point the TNS_ADMIN to a folder with the wallet enabled sqlnet.ora and tnsnames and all is good.
sample pseudo code is at end of post

2) The problem above for us, came from two installations of Oracle on a machine. One installation being a incomplete instantclient.

Happy new year

Alex

code sample:
begin
//Set tns_admin for application if required.
SetEnvironmentVariable('TNS_ADMIN', 'C:\oracle\product\11.2.0\client_1\network\admin');
EnvValue := GetEnvironmentVariable('TNS_ADMIN');
SetEnvironmentVariable('NLS_LANG', 'your NLS code');
SetEnvironmentVariable('PATH','c:\oracleclient');
SetEnvironmentVariable('UPDATEPATH','C:\oracleclient');

session1.ConnectString := '/@TNS_ALIAS;
//or
//session1.ConnectString := 'Data Source=TNS_ALIAS;User ID=;Password=';
///session1.ConnectString := 'Data Source=TNS_ALIAS';
session1.Connect;
end;

MaximG
Devart Team
Posts: 1822
Joined: Mon 06 Jul 2015 11:34

Re: Oracle wallet and ODAC

Post by MaximG » Tue 03 Jan 2017 10:23

We are glad to see the problem resolved. Please don't hesitate to contact us with questions concerning ODAC usage.

Post Reply