我有一个依赖于加载db2驱动程序的应用程序。我得到了db2jcct2.dll没有加载的奇怪错误,所以我确保将它添加到我的lib路径中:http://www-01.ibm.com/support/docview.wss?uid=swg21419978我也确保它在程序中添加到java.library.path启动。完成后,我得到以下错误/堆栈跟踪。
com.ibm.db2.jcc.c.SqlException: Failure in loading T2 native library db2jcct2, reason: java.lang.UnsatisfiedLinkError: C:\Program Files (x86)\IBM\SQLLIB\BIN\db2jcct2.dll: Can't find dependent libraries
at com.ibm.db2.jcc.t2.a.a(a.java:31)
at com.ibm.db2.jcc.t2.T2Configuration.<clinit>(T2Configuration.java:84)
at com.ibm.db2.jcc.t2.a.a(a.java:31)
at com.ibm.db2.jcc.DB2Driver.connect(DB2Driver.java:174)
at com.ibm.db2.jcc.t2.T2Configuration.<clinit>(T2Configuration.java:84)
at com.ibm.db2.jcc.DB2Driver.connect(DB2Driver.java:174)
at java.sql.DriverManager.getConnection(DriverManager.java:571)
at java.sql.DriverManager.getConnection(DriverManager.java:571)
at java.sql.DriverManager.getConnection(DriverManager.java:215)