Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.server -> java ORA-22920: row containing the LOB value is not locked
I've seen many posts about this Oracle error w/ clobs. The code below
contains the "FOR UPDATE" though, and I still get this error (on
occasion)
java full version "1.3.0"
Oracle8i Enterprise Edition Release 8.1.7.0.0 - Production
classes12.zip
I get the Oracle exception on the flush() command. Should I not be doing this?
Thanks for any insight.
con.setAutoCommit(false);
stmt = con.prepareCall("SELECT t1.clob_data FROM t_clob t1,t_users t2
WHERE t1.clob_id = t2.ssi_config AND t2.userid = ? FOR UPDATE");
stmt.setInt(1,i_user_id);
stmt.execute();
ResultSet myclobrs = stmt.getResultSet();
myclobrs.next();
oracle.sql.CLOB new_perm_clob = (oracle.sql.CLOB)myclobrs.getClob(1);
java.io.OutputStream permission_stream =
new_perm_clob.getAsciiOutputStream();
permission_stream.write(new_perms_wr.toString().getBytes());
permission_stream.flush();
if (stmt != null) stmt.close();
if (myclobrs != null) myclobrs.close();
con.commit();
con.setAutoCommit(true);
Received on Wed May 07 2003 - 08:21:33 CDT
![]() |
![]() |