1 Reply Latest reply on Mar 6, 2003 7:56 AM by davidjencks

    Bug in LocalManagedConnection autocommit?

      I want to make sure, that I understand things correctly before I report this as a bug. I'm using jboss 3.0.6.

      If you want to update a row with both normal data and LOBs in Oracle, you must send two SQL statements, one to UPDATE the normal data and one to SELECT the Lobs for modification. In order to handle this in a general way, we have written a PreparedStatement Wrapper that make two statements out of the singe UPDATE statements.

      We want this to work both stand-alone and in an ejbStore context. So we have a look at the connection's autocommit. If it is true, we set it to false, execute the two statements, commit and restore it to true. While this works as stand-alone, we get a "You cannot commit during a managed transaction!" in ejbStore. How comes that? We expected autocommit to be false! So we wouldn't commit at all!

      We find that the connections implemented as LocalManagedConnections have getAutoCommit() == true. (Simply print the getAutoCommit() of your connection within an ejbStore.) Is this a bug?

      - Michael