如何测试与 db2 数据库的连接 [英] How to test the connection to a db2 database
本文介绍了如何测试与 db2 数据库的连接的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我需要测试与 db2 数据库的连接.
I need to test the connection to a db2 database.
对于 oracle 数据库,我会执行select * from dual"来执行此操作.
With oracle databases I'd execute a 'select * from dual' in order to do this.
但 dual 是特定于 oracle 的.db2有类似的规范测试sql语句吗?
But dual is specific for oracle. Is there a similar canonical test sql statement for db2?
推荐答案
SELECT 1 FROM SYSIBM.SYSDUMMY1
那么便宜
从 SYSIBM.SYSDUMMY1 中选择当前 SQLID
这篇关于如何测试与 db2 数据库的连接的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文