Your insert is indeed executed on the database, but only your transaction can see the change. Check things in a different transaction to see if you're getting it right. I.e.
1. Set auto-commit to false 2. Insert 3. Create a break point before the commit 4. Use squirrel or phpmyadmin or your favorite database tool, to check whether the table was updated. It shouldn't be 5. Commit 6. Check again in your tool. Now, the update should be visible Note, there might be some confusion with Hibernate, which has the notion of "flushing". Hibernate has a second-level cache. When you write data, it is possible that the writes are kept in memory first, before they're "flushed" to the database. jOOQ has no second-level cache, but executes everything directly on your database connection. Cheers Lukas 2012/4/1 FB <[email protected]> > Hi, > > I read on the documentation that JOOQ doesn't provide transaction > management and I have to take care of that. > So to start a transaction and commit/rollback the data I was thinking > to do: > > > datasourse.setAutoCommit(false) //this set > connection.setAutoCommit(false) > > factory.insertInto(T, T.FIRST_NAME, T.LAST_NAME) > .values("laura", "natali") > .execute(); > > datasourse.commit(); > > > The problem is the factory inserts the data before the .commit() > command. > Is there another way to do that? > > Thanks. F.
