我想知道是否有人在尝试连接到 DB2 数据库时遇到过以下错误:
连接失败。
错误类型:ODBC 错误。尝试的 ODBC 操作:
SQLDriverConnect.[HY000:-1334:在 SQLHANDLE 上][微策略][ODBC DB2 线路协议驱动程序][DB2]未知错误:SQLCODE -1334
我查看了 DB2 文档,但找不到 SQL 代码错误。我不知道发生了什么。我是否必须更新或降级 ODBC 驱动程序?
在版本
9.3.0 中,有一个与版本 9.2.1 和 DB2 on Windows 相关的问题的错误修复,
如下所示或者只是你有一个错误的配置(即数据库名称),就像这个讨论中的那个人一样。
不确定您正在查看什么文档,但这里是:
$ db2 ? sql1334
SQL1334N The database server or DB2 Connect server cannot be used to
route a remote request to a second database server in this
configuration.
Explanation:
An attempt was made to route a request through a database server node or
DB2 Connect server node using an unsupported combination of client and
target database server, or from a non-LUW DRDA client to a DRDA target
database through a LUW database server or DB2 Connect server. The
request must be routed directly from the client to the node on which the
target database is running.
User response:
Uncatalog the database at the client machine and then catalog the
database specifying the node on which the database actually resides.
Ensure that the node is also cataloged.