Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to start Oracle SQL Developer 4 using 32 bit JDK on Win 64?

I need to connect to a database and use a wallet file. If i try with my SQL Developer i end up with "ocijdbc.dll: Cant load IA 32bit .dll on a AMD 64-bit platform."

I have both installed JDK 32 bit (in C:Prog32bit) and JDK 64 bit (C:Prog) for development.

I tried to set JavaHome in sqldeveloper/bin/sqldeveloper.conf manually SetJavaHome C:\Program Files (x86)\Java\jdk1.7.0_51

My next step was to edit %USER_HOME%/sqldeveloper/sqldeveloper.conf and I set SetJavaHome there too, but none didn't work.

Next step was, i edited sqldeveloper/bin/sqldeveloper.bat and set:

JAVA_HOME="C:\Program Files (x86)\Java\jdk1.7.0_51"
path="C:\Program Files (x86)\Java\jdk1.7.0_51\bin%"

java.exe -Xmx640M -Xms128M -Xveri.... 

My last try was to use the command line (as I would do on linux) and run:

D:\sqldeveloper>PATH="C:\Program Files (x86)\Java\jdk1.7.0_51\bin"
D:\sqldeveloper>java -version
java version "1.7.0_51"
Java(TM) SE Runtime Environment (build 1.7.0_51-b13)
Java HotSpot(TM) Client VM (build 24.51-b03, mixed mode, sharing)
D:\sqldeveloper>sqldeveloper.exe

But i still receive the message sqldeveloper is running 64 bit Java.

I found a workarround. An older version of SQL Developer (bundeld with jdk) is available at http://www.oracle.com/technetwork/developer-tools/sql-developer/downloads/sqldev-downloads-v322-2080107.html

like image 468
Martin Baumgartner Avatar asked Mar 06 '14 13:03

Martin Baumgartner


People also ask

How do you check SQL Developer is 32 or 64 bit?

If the two directories $ORACLE_HOME/lib32 and $ORACLE_HOME/lib are existing then it is 64-bit. If there is only an ORACLE_HOME/lib directory then it is a 32-bit client.

What is the difference between 32 bit and 64 bit Oracle client?

1) 32bit Oracle is the Oracle that runs on all operating systems. It has a 4gig (or less, depending on OS) address limit. It uses 32bit pointers which are limited to 4gig. Now, 64bit can address a much larger memory space.


1 Answers

The main problem in this case is that you have installed a 32 bits Oracle Driver to connect to your database in a 64 bit machine. There is no problem with that but you need to set SetJavaHome to a jdk directory that contains 32 bits version.

In sqldeveloper 4 you need to edit the file:

"C:\Users\username\AppData\Roaming\sqldeveloper\1.0.0.0.0\product.conf"

and inside this config file change the default directory for jdk1.7.0_71 32 bits is like this:

SetJavaHome C:\Program Files (x86)\Java\jdk1.7.0_71

After you use this path, check in Task Manager that your process sqldeveloper looks like this: sqldeveloper.exe *32

If your process starts with that "*32" you could be able to connect using your 32 bits oracle driver.

like image 183
svcabre Avatar answered Oct 03 '22 06:10

svcabre