can't initialize OCI

Discussion of open issues, suggestions and bugs regarding ODAC (Oracle Data Access Components) for Delphi, C++Builder, Lazarus (and FPC)
Post Reply
bds2006
Posts: 2
Joined: Thu 04 Nov 2010 11:49

can't initialize OCI

Post by bds2006 » Thu 04 Nov 2010 12:06

Hi,
I work on Borland Developer Studio 2006 with ODAC 5.80.0.35
I have client oracle : Oracle Database 10g Enterprise Edition Release 10.2.0.4.0 - 64bit
I can launch my application with login/pwd oracle and it's work fine.

When i go in the code to the Session Editor the connection is ok and I see the oci.dll
OCI: Version 10.2.0.1.0
DLL: D:\oracle\product\10.2.0\client_1\BIN\oci.dll

But when i want to debug in my ide bds2006 there's an exception on the TOrassession with the message "can't initialize OCI. Error -1"

Can everyone help me?
thanks

AlexP
Devart Team
Posts: 5530
Joined: Tue 10 Aug 2010 11:35

Post by AlexP » Thu 04 Nov 2010 14:32

Hello,

As I can see you have two different oracle clients - 10.2.0.4.0 and 10.2.0.1.0, and one of them is x32, and ODAC can work with it. ODAC is an x32 application and can't work with x64 dll in any modes (run-time, design-time). Check that you have chosen the correct home property in the TOraSession window - it should be the x32 client.

bds2006
Posts: 2
Joined: Thu 04 Nov 2010 11:49

Post by bds2006 » Thu 04 Nov 2010 14:55

OK.
But I don't understand why my application is runing when I launch it without debugging.
Have you an idea?

AlexP
Devart Team
Posts: 5530
Joined: Tue 10 Aug 2010 11:35

Post by AlexP » Mon 15 Nov 2010 10:14

Hello,

Please set/create the TNS_ADMIN enviroment variable to the path to your tnsnames.ora file and try again

Post Reply