Hi, I could create a test case and fix the problem. Thanks a lot for your help!
Sooner or later I want to replace the LOB mechanism, the problem is not (only) the number of files but also possible duplication (multiple files containing the same data). I guess something like the data store would be better: http://wiki.apache.org/jackrabbit/DataStore - but with real-time garbage collection (using back-links), splitting files in blocks of the same size, and maybe a faster hashing algorithm. Regards, Thomas On Sat, Sep 5, 2009 at 9:54 PM, neutronlabs <[email protected]> wrote: > > Hi, > > I have a table post: > > create table post( > id INT PRIMARY KEY, > title VARCHAR, > text CLOB, > user_ip VARCHAR, > ts BIGINT > ) > > filled with about 300 entries > > and when calling this method in Java: > > public long upadatePostsSeqPrepared(String text) throws > SQLException { > PreparedStatement pstmt = con.prepareStatement("update post > set text = ?"); > long rv = System.nanoTime(); //real Start > > pstmt.setCharacterStream(1, new StringReader(text)); > pstmt.executeUpdate > (); > // > <--- H2.java Line 638 > > return rv; > } > > I get this Exception: > > 05.09.2009 20:11:50 qminidbperformancesuite.Benchmark run > SCHWERWIEGEND: null > org.h2.jdbc.JdbcSQLException: Fehler beim Umbenennen der Datei C: > \QMDBPS\H2\db.lobs.db\6.lobs.db\155 > 5.temp.db (not found) nach C:\QMDBPS\H2\db.lobs.db\6.lobs.db > \1555.t47.lob.db > Error while renaming file C:\QMDBPS\H2\db.lobs.db\6.lobs.db > \1555.temp.db (not found) to C:\QMDBPS\H2 > \db.lobs.db\6.lobs.db\1555.t47.lob.db; SQL statement: > update post set text = ? [90024-117] > at org.h2.message.Message.getSQLException(Message.java:105) > at org.h2.message.Message.getSQLException(Message.java:116) > at org.h2.store.fs.FileSystemDisk.rename(FileSystemDisk.java: > 74) > at org.h2.util.FileUtils.rename(FileUtils.java:252) > at org.h2.value.ValueLob.renameFile(ValueLob.java:813) > at org.h2.value.ValueLob.link(ValueLob.java:515) > at org.h2.index.ScanIndex.add(ScanIndex.java:110) > at org.h2.table.TableData.addRow(TableData.java:123) > at org.h2.table.Table.updateRows(Table.java:395) > at org.h2.command.dml.Update.update(Update.java:132) > at org.h2.command.CommandContainer.update > (CommandContainer.java:72) > at org.h2.command.Command.executeUpdate(Command.java:208) > at org.h2.jdbc.JdbcPreparedStatement.executeUpdateInternal > (JdbcPreparedStatement.java:140) > at org.h2.jdbc.JdbcPreparedStatement.executeUpdate > (JdbcPreparedStatement.java:129) > at qminidbperformancesuite.db.H2.upadatePostsSeqPrepared > (H2.java:638) > at qminidbperformancesuite.Benchmark.updatePostsBench > (Benchmark.java:775) > at qminidbperformancesuite.Benchmark.runRawUpdateBenchmark > (Benchmark.java:930) > at qminidbperformancesuite.Benchmark.runFullBenchmark > (Benchmark.java:987) > at qminidbperformancesuite.Benchmark.run(Benchmark.java:1023) > at java.lang.Thread.run(Thread.java:619) > > Suprisingly enough "update post set text = ? where id = ?" works fine, > and when trying to do "update post set text = 'asdf'..." in the > Webinterface it works too. > > > > --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "H2 Database" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/h2-database?hl=en -~----------~----~----~----~------~----~------~--~---
