Hi!
I have a code on Java for reading Clob data and there were some crazy things ... there are differents in JDBC drivers of Oracle9.2 and Oracle9.0.1 and some things which I can not understand.
I've the following code which works on Oracle9.0.1 with its driver (classes12.jar) but doesn't work on Oracle9.2
ResultSet rsResults = .......;
...
...
java.sql.Clob clobText = rsResults.getClob(2);

Oracle9.2 generates this error:

java.sql.SQLException: No more data to read from socket
at oracle.jdbc.dbaccess.DBError.throwSqlException(DBE rror.java:134)
at oracle.jdbc.dbaccess.DBError.throwSqlException(DBE rror.java:179)
at oracle.jdbc.dbaccess.DBError.check_error(DBError.j ava:1160)
at oracle.jdbc.ttc7.MAREngine.unmarshalUB1(MAREngine. java:963)
at oracle.jdbc.ttc7.MAREngine.unmarshalSB1(MAREngine. java:893)
at oracle.jdbc.ttc7.v8TTILob.receiveReply(v8TTILob.ja va:955)
at oracle.jdbc.ttc7.v8TTILob.getLength(v8TTILob.java: 297)
at oracle.jdbc.ttc7.TTC7Protocol.lobLength(TTC7Protoc ol.java:2705)
at oracle.sql.LobDBAccessImpl.length(LobDBAccessImpl. java:468)
at oracle.sql.clob.length(CLOB.java:214)


After that, Ive tried with replacing of java.sql.Clob to oracle.sql.CLOB
as :

oracle.sql.CLOB clobText = (oracle.sql.CLOB)rsResults.getClob( ... );

and it sometime works, seometimes doesn't work or Oracle9.2 : returns the same error:

java.sql.SQLException: No more data to read from socket
....
....
....
(LobDBAccessImpl.java:468)
at oracle.sql.clob.length(CLOB.java:214)



Why that clob.length() does not work on Oracle9.2 but work on Oracle9.0.1.
Or Why that oracle.sql.clob.length() does not work correctly

Thanks,
Arman.