db2 - DB2 error: SQL10007N Message "-1390" could not be retrieved. Reason code: "3"
问题描述
I get the following error when trying to connect to a db2 db:
$ /opt/ibm/db2/V10.5/bin/db2 connect to SRVO
SQL10007N Message "-1390" could not be retrieved. Reason code: "3".
However I don't experience any problems when connecting to it from DBeaver. What could be the cause of the error?
解决方案
The message says:
SQL1390C The environment variable DB2INSTANCE is not defined or is invalid.
and the SQL10007 is also returned because of this - so fix the DB2INSTANCE by setting it to your current instance.
set DB2INSTANCE=whateveryourinstanceis
Addition: Your driver seetting within DBeaver should point to the correct location of following files: db2java.zip db2jcc_license_cu.jar (or similar) db2jcc4.jar
推荐阅读
- hibernate - Hibernate/JPA 缓存对多节点架构的影响
- visual-studio-code - VS Code Intellisense 显示废话
- android - 任务 ':app:generateDebugBuildConfig' 执行失败。飘飘然
- angular - 输入 Angular [ngClass] - [(ngModel)] 时更改边框输入
- r - R,每列/样本删除零个条目并计算唯一出现。将它们绘制为堆积条形图
- azure-cognitive-search - "SearchAsync" InvalidCastException Null 对象无法转换为值类型
- mysql - 即使在模型中设置公共 $increments = false 之后,Laravel 8 也会自动增加列
- python - 如何解决 conda 的 pycosat 依赖?
- java - 摩托罗拉 MC9000 手持设备失去与服务器的连接(服务器或网络参数?)
- swift - 无法将“查询”类型的值转换为预期的条件类型“布尔”