1. 程式人生 > >使用plSQL連線Oracle的問題(SQL*Net not properly installed)

使用plSQL連線Oracle的問題(SQL*Net not properly installed)

在64位機器上了64位的oracle客戶端。
然後裝上PL/SQL Developer,但是連線oracle老報這個錯:
Initialization error
SQL*Net not properly installed

OracleHomeKey:
OracleHomeDir:

原因大概是Oracle10g的安裝目錄結構變了,需要在PLSQL Developer中重新配置ORACLE_HOME and "OCI Library"的目錄。

步驟如下:

在PLSQL Developer選擇Tools > Preferences > options > 下的如圖所示:"Oracle Home" and "OCI Library"

Oracle10g裝在d:\oracle\ Oracle Home為d:\oracle\product\10.1.0

OCI Library為d:\oracle\product\10.1.0\Db_1\BIN\oci.dll

配置完以後重新啟動PLSQL Developer,登入成功



配置過後登陸時仍然報錯:
Could not load "……/bin/oci.dll"
OCIDLL forced to……
LoadLibrary(……oci.dll) returned 0

解決辦法是:在64位的機器上安裝32位的Oracle客戶端。這樣的話便連線成功。

依據:
從安裝角度考慮,32bit的平臺(作業系統和硬體系統)只支援32bitORACLE的安裝;
64bit平臺既支援32bitORACLE的安裝也支援64位ORACLE的安裝;

根據PL/SQL Developer的官方論壇裡面的帖子:
quote:
--------------------------------------------------------------------------------
I am not too fond of installing both 32 and 64 bit oracle clients on same machine - does it work at all?
--------------------------------------------------------------------------------

Yes, this works fine. --這是管理員的回覆

PL/SQL Developer is written in Delphi.
The first thing that needs to become available is a 64 bit version of the Delphi IDE.

還有另外一個帖子也提到:
Hi when install in Windows Server 2003 R2 X64.

When I try to connect an account , I have the following message :

Initialization error
Could not load"E:/oracle/product/10.2.0/bin/oci.dll"

--以下是管理員的回覆
Is this a 64 bit Oracle Client DLL?
If so, please note that you need to install a 32 bit Oracle Client to use a 32 bit application like PL/SQL Developer.

呼,終於解決了,在客戶的web機上無法用PL/SQL連到linux上的Oracle資料庫