W
WorldCreater
Unregistered / Unconfirmed
GUEST, unregistred user!
sql2000中的image型字段究竟应怎么读啊?它的jdbc驱动不支持?
部分代码:
try {
System.out.println ("debug1111111111");
Class.forName(driverClass);
Connection cnn = DriverManager.getConnection(url, userName, userPassword);
Statement stmt = cnn.createStatement();
ResultSet rs = stmt.executeQuery("select originalText.original_Name,originalText.type, originalTextInfo.code from Original_Text originalText, Original_Text_Info originalTextInfo where originalText.id=originalTextInfo.id and originalText.id='" + id + "'");
byte[] buf = new byte[1024];
if (rs.next()) {
System.out.println ("debug222222222");
Blob code = (Blob) rs.getBlob("code");
System.out.println ("debug33333333333");
InputStream codeStream = code.getBinaryStream();
System.out.println ("debug444444444444");
=================================
出错信息:
debug1111111111
debug222222222
java.sql.SQLException: [Microsoft][SQLServer 2000 Driver for JDBC]Unsupported data conversion.
sql2000的驱动不支持????????????????
部分代码:
try {
System.out.println ("debug1111111111");
Class.forName(driverClass);
Connection cnn = DriverManager.getConnection(url, userName, userPassword);
Statement stmt = cnn.createStatement();
ResultSet rs = stmt.executeQuery("select originalText.original_Name,originalText.type, originalTextInfo.code from Original_Text originalText, Original_Text_Info originalTextInfo where originalText.id=originalTextInfo.id and originalText.id='" + id + "'");
byte[] buf = new byte[1024];
if (rs.next()) {
System.out.println ("debug222222222");
Blob code = (Blob) rs.getBlob("code");
System.out.println ("debug33333333333");
InputStream codeStream = code.getBinaryStream();
System.out.println ("debug444444444444");
=================================
出错信息:
debug1111111111
debug222222222
java.sql.SQLException: [Microsoft][SQLServer 2000 Driver for JDBC]Unsupported data conversion.
sql2000的驱动不支持????????????????