当前位置: 代码迷 >> SQL >> Oracle及时客户端Instant Client,方便使用PLSQL Developer方法
  详细解决方案

Oracle及时客户端Instant Client,方便使用PLSQL Developer方法

热度:55   发布时间:2016-05-05 10:44:21.0
Oracle即时客户端Instant Client,方便使用PLSQL Developer方法

背景:64位操作系统中、不安装Oracle-32bit客户端,方便使用PLSQL Developer(不支持64bit位Oracle客户端)

1,下载Oracle简易客户端Instant Client

下载地址:http://www.oracle.com/technetwork/topics/winsoft-085727.html 。 下载instantclient-basic-win32-11.2.0.1.0.zip、instantclient-odbc-win32-11.2.0.1.0.zip

2,安装Instant Client

解压缩下载的两种zip文件。
同时选择两个ZIP文件,,然后右键选择解压到当前目录。
比如解压后我的目录是D:\oracle\product\instantclient_11_2

3,设置环境变量

3.1设置环境变量TNS_ADMIN

TNS_ADMIN比如,=D:\oracle\product\instantclient_11_2\NETWORK\ADMIN。(默认无子目录,NETWORK\ADMIN,手动创建即可)

注:手动创建的子目录NETWORK\ADMIN\下,需要创建文件tnsnames.ora
# tnsnames.ora Network Configuration File: D:\oracle\product\instantclient_11_2\NETWORK\ADMIN\tnsnames.ora# Generated by Oracle configuration tools.ORACLR_CONNECTION_DATA =  (DESCRIPTION =    (ADDRESS_LIST =      (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1521))    )    (CONNECT_DATA =      (SID = CLRExtProc)      (PRESENTATION = RO)    )  )ORCL =  (DESCRIPTION =    (ADDRESS_LIST =      (ADDRESS = (PROTOCOL = TCP)(HOST = 16101218-2)(PORT = 1521))    )    (CONNECT_DATA =      (SERVER = DEDICATED)      (SERVICE_NAME = orcl)    )  )133_NSDEV =  (DESCRIPTION =    (ADDRESS_LIST =      (ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.0.133)(PORT = 1521))    )    (CONNECT_DATA =      (SERVER = DEDICATED)      (SERVICE_NAME = NSDEV)    )  )

3.2设置环境变量NLS_LANG(设置方法如同3.1)

比如NLS_LANG=SIMPLIFIED CHINESE_CHINA.ZHS16GBK
"SIMPLIFIED CHINESE_CHINA.ZHS16GBK"的值,要视情况而定。(select userenv('language') from dual;)

4,最后一步,设置PLSQL Developer

打开plsqldev.exe,进入菜单tool->Preferences->Connection(工具->首选项->连接),设置如图。




  相关解决方案