简体   繁体   中英

SystemError: error return without exception set when connecting to the database using ibm_db

I am unable to connect to the database. I was trying to run an automation script through Robot Framework for which I installed ibm_db module using pip. But the error is so generic that I couldn't get it resolved.

>>> import ibm_db
>>> conn = ibm_db.connect("DATABASE=<database>;HOSTNAME=<host.co
m>;PORT=<port>;PROTOCOL=TCPIP;UID=<userid>;PWD=<password>;", "", "")
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
SystemError: error return without exception set

IBM Db2 database is installed on a remote server which runs on Windows 7. I am able to connect to the database manually. IBM_DB module version is 2.0.7. Python version is 2.7.9 and runs on a Windows 10 system. I was able to run the same script from another system with similar configurations.

我在连接到 IBM DB 时遇到了同样的问题。我的机器上安装了 DB2 服务器版本,只需将其卸载。现在它对我来说工作正常,似乎与 DB2 服务器版本文件存在一些兼容性问题。

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM