my dog learned polymorphism*
The moose likes JDBC and the fly likes connect to db2 8 error using JDBC Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Databases » JDBC
Bookmark "connect to db2 8 error using JDBC" Watch "connect to db2 8 error using JDBC" New topic
Author

connect to db2 8 error using JDBC

hu jingxuan
Greenhorn

Joined: Aug 18, 2003
Posts: 2
my code is
Class.forName( "com.ibm.db2.jcc.DB2Driver" );
Connection cn = DriverManager.getConnection("jdbc b2://victor:50000/TOOLSDB","db2admin","db2admin");
the warning is
com.ibm.db2.jcc.b.DisconnectException: encoding not supported!!
at com.ibm.db2.jcc.a.ba.a(ba.java:499)
at com.ibm.db2.jcc.a.bb.br(bb.java:3904)
...
at com.ibm.db2.jcc.a.b.<init>(b.java:207)
at com.ibm.db2.jcc.DB2Driver.connect(DB2Driver.java:244)
at java.sql.DriverManager.getConnection(DriverManager.java:512)
at java.sql.DriverManager.getConnection(DriverManager.java:171)
at myprojects.dbcon.DbCon.connection1(DbCon.java:126)
at myprojects.dbcon.DbCon.main(DbCon.java:165)
The db2's version is Chinese Version.
 
Don't get me started about those stupid light bulbs.
 
subject: connect to db2 8 error using JDBC
 
Similar Threads
java.sql.SQLException: No suitable driver
DB2 connection error
java DB2 program
Problem in JDBC connection in Websphere 3.5.0
java.sql.SQLException: No suitable driver