我正在使用 Windows 机器连接到远程 DB2 实例。碰到这个问题
SQL1531N The connection failed because the name specified with the DSN connection string keyword could not be found in either the db2dsdriver.cfg configuration file or the db2.cli.ini configuration file. Data source name specified in the connection string: <DSN>
我已经使用它配置了 ODBC 数据源,ODBC Data Source Administrator
它已成功连接。
经过进一步调查,我无法在 IBM DATA SERVER DRIVER 文件夹中找到 db2dsdriver.cfg。我能够找到 db2dsdriver.lvl 和 dbs2dsdriver.xds。只是不是 .cfg 文件。我也不确定 HammerDB 在哪里寻找配置文件。
我从网站上查看了 DB2 的配置,但无法从那里获得任何有用的信息。https://www.hammerdb.com/docs/ch04s02.html