我想使用JDBC和python连接到Oracle数据库。我有一台Windows 7计算机。我已经安装了jaydebeapi
软件包。
我的Windows 7计算机已安装32位JRE,并且不能选择安装64位版本。实际的Windows 7安装是64位。
我收到一条错误消息,提示它找不到我的JAVA_HOME。如何手动指定?
我得到的回溯:
Traceback (most recent call last):
File "<stdin>", line 20, in <module>
File "Z:\Continuum\anaconda3\lib\site-packages\jaydebeapi\__init__.py", line 381, in connect
jconn = _jdbc_connect(jclassname, url, driver_args, jars, libs)
File "Z:\Continuum\anaconda3\lib\site-packages\jaydebeapi\__init__.py", line 175, in _jdbc_connect_jpype
jvm_path = jpype.getDefaultJVMPath()
File "Z:\Continuum\anaconda3\lib\site-packages\jpype\_core.py", line 337, in getDefaultJVMPath
return finder.get_jvm_path()
File "Z:\Continuum\anaconda3\lib\site-packages\jpype\_jvmfinder.py", line 184, in get_jvm_path
.format(self._libfile))
jpype._jvmfinder.JVMNotFoundException: No JVM shared library file (jvm.dll) found. Try setting up the JAVA_HOME environment variable properly.