繁体   English   中英

无法使用Robot框架中的ibm_db api连接到DB2

[英]Can not connect to DB2 using ibm_db api in Robot framework

我使用以下语句在RIDE编辑器中连接到DB2数据库(在IBM i Access服务器上)

Connect To Database Using Custom Params    ibm_db    'DATABASE=mydb;HOSTNAME=10.53.x.x;PORT=8471;PROTOCOL=TCPIP;UID=myuser;PWD=xxxx;','',''

但是它总是连接并且无法完成。 我可以远程登录端口8471(这是用于访问数据库的端口)

当我尝试另一个端口时,出现以下错误:

SQL30081N A communication error has been
detected. Communication protocol being used: "TCP/IP". Communication
API being used: "SOCKETS". Location where the error was detected:
"x.x.x.x". Communication function detecting the error: "recv".
Protocol specific error code(s): "*", "*", "0". SQLSTATE=08001

你知道如何解决这个问题吗?

尝试使用ibm_db_dbi而不是ibm_db

它对我有用。

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

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