Skip to Main Content

Java Database Connectivity (JDBC)

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Protocol Confusion of freeTDS jdbc driver, please help!

843853Jun 15 2001 — edited Oct 23 2003
I use freeTDS jdbc driver to connect to MS SQL 2000. In my programme, firstly I need to select sth out, and base on this update the other field in the same table. TOC will like that

...
Statement stmt1 = conn.createStatement();
ResultSet rs1 = stmt1.executeQuery("select sth from table");
...
stmt1.executeUpdate("update table set field1 = 'xxx'");

exception throw: java.sql.SQLException: Protocol confusion. Got a 0x79 packet

I checked from the source of TDS driver, this exception throws when the sql query output is not a resultset.

These 2 querys are prefectly okay individually, I tried to reverse the order, doesn't work neither. Even I disconnect the DB Connection and reconnect it before running the 2nd query, it won't help.

Please help!
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Nov 20 2003
Added on Jun 15 2001
13 comments
345 views