File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes JDBC and the fly likes Error writing greater than 4000 chars to CLOB Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login


Win a copy of The Mikado Method this week in the Agile and other Processes forum!
JavaRanch » Java Forums » Databases » JDBC
Reply Bookmark "Error writing greater than 4000 chars to CLOB" Watch "Error writing greater than 4000 chars to CLOB" New topic
Author

Error writing greater than 4000 chars to CLOB

Jon Wynett
Greenhorn

Joined: Jun 28, 2004
Posts: 10
Hi:

I'm using Oracle10g with the thin client and trying to write data to a CLOB column. My code works fine for 4000 chars or less. More chars causes the exception shown below. Code is also shown here. Thanks for your help.

InputStream is = new ByteArrayInputStream(value.getBytes());
ps.setAsciiStream(idx, is, value.getBytes().length);
======

java.sql.SQLException: No more data to read from socket
at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:189)
at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:231)
at oracle.jdbc.dbaccess.DBError.check_error(DBError.java:985)
at oracle.jdbc.ttc7.MAREngine.unmarshalUB1(MAREngine.java:746)
at oracle.jdbc.ttc7.MAREngine.unmarshalSB1(MAREngine.java:705)
at oracle.jdbc.ttc7.Oall7.receive(Oall7.java:381)
at oracle.jdbc.ttc7.TTC7Protocol.doOall7(TTC7Protocol.java:1478)
at oracle.jdbc.ttc7.TTC7Protocol.parseExecuteFetch(TTC7Protocol.java:888)
at oracle.jdbc.driver.OracleStatement.executeNonQuery(OracleStatement.java:2076)
at oracle.jdbc.driver.OracleStatement.doExecuteOther(OracleStatement.java:1986)
at oracle.jdbc.driver.OracleStatement.doExecuteWithTimeout(OracleStatement.java:2697)
at oracle.jdbc.driver.OraclePreparedStatement.executeUpdate(OraclePreparedStatement.java:457)
at com.evermind.sql.FilterPreparedStatement.executeUpdate(FilterPreparedStatement.java:240)
at com.evermind.sql.FilterPreparedStatement.executeUpdate(FilterPreparedStatement.java:240)
at com.evermind.sql.PreparedStatementBCELProxy.executeUpdate(PreparedStatementBCELProxy.java:46)
Annie Smith
Ranch Hand

Joined: Mar 05, 2005
Posts: 172
You can check
here


Cheers!<br /><b>Annie</b>
 
I agree. Here's the link: http://zeroturnaround.com/jrebel - it saves me about five hours per week
 
subject: Error writing greater than 4000 chars to CLOB
 
Similar Threads
Insert file to Oracle's BLOB
init.ora parameter HELP
select with an "in" clause...
ORACLE JDBC ERROR ORA-00600
invalid host/bind variable name