Shouldn't the test be asserting that information_schema.lobs be one row
not information_schema.lob_data? Couldn't a large lob have
multiple information_schema.lob_data rows?
On Tuesday, February 11, 2014 1:35:58 AM UTC-6, Noel Grandin wrote:
>
>
> I reduced the test-case, but I haven't found the problem yet.
>
> (Add this method to the TestLob unit test class)
>
> private void testCleaningUpLobsOnRollback() throws Exception {
> deleteDb("lob");
> Connection conn = getConnection("lob");
> Statement stat = conn.createStatement();
> stat.execute("CREATE TABLE test(id int, data CLOB)");
> conn.setAutoCommit(false);
> stat.executeUpdate("insert into test values (1, '" +
> MORE_THAN_128_CHARS + "')");
> conn.rollback();
> ResultSet rs = stat.executeQuery("select count(*) from test");
> rs.next();
> assertEquals(0, rs.getInt(1));
> rs = stat.executeQuery("select count(*) from
> information_schema.lob_data");
> rs.next();
> assertEquals(0, rs.getInt(1));
> conn.close();
> }
>
>
--
You received this message because you are subscribed to the Google Groups "H2
Database" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/h2-database.
For more options, visit https://groups.google.com/groups/opt_out.