设置PLSQL+Developer访问本机64位Oracle+服务器

转自:http://carltao.blog.51cto.com/856514/196838 

 

由于在本机Vista X64上安装了64位的Oracle,结果试图使用PLSQL Developer去访问它的时候,报告说无法加载oci.dll文件。原来oci.dll是64位的,32位应用程序PLSQL Developer自然无法加载了。
试验了下,解决办法如下:

  • 1. 下载32位Oracle InstantClient,并展开到某目录,例如C:\oracle\instantclient_10_2;
  • 2. 将系统的tnsnames.ora拷贝到该目录下;
  • 3. 在PLSQL Developer中设置Oracle_Home和OCI Library,如下图所示

 

  • 4. 在PLSQL Developer目录下编辑如下bat文件,替换其快捷方式,启动PLSQL Developer:
@echo off
set path=C:\oracle\instantclient_10_2
set ORACLE_HOME=C:\oracle\instantclient_10_2
set TNS_ADMIN=C:\oracle\instantclient_10_2
set NLS_LANG=AMERICAN_AMERICA.ZHS16GBK
start plsqldev.exe

  注:NLS_LANG前半部分必须是AMERICAN_AMERICA,因为instant client不支持其他语言;而后半部分可以根据你数据库的字符集调整,如果数据库采用AL32UTF8,则可以设置AL32UTF8。

 

其他:

Quick post: I was trying to connect to a 64-bit Oracle database using PL/SQL Developer. Despite ORACLE_HOME being set the right values and oci.dll available, PL/SQL Developer could not connect to the database.

Further probing indicated that the Oracle installation was a 64-bit one, and PL/SQL Developer is incapable of loading 64-bit version of oci.dll file. To fix this, download the 32-bit version of Oracle Instant Client, extract it to a directory such as \instant_client.

Next, configure PL/SQL Developer to use this version by clicking on Tool menus -> Preferences. Under Oracle Home, point to the location where you had extracted Instant client (\instant_client, in this case)  and under location of OCI Library, point to the oci.dll file present in location where you had extracted Instant client ( \instant_client\oci.dll). Restart PL/SQL Developer and you should be able to connect now.

 


方法可行~
  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值