Do you have a question? Post it now! No Registration Necessary.  Now with pictures!

Threaded View

Does START TRANSACTION and COMMIT apply only to the Connection for which the
START TRANSACTION statement was performed? So if a second Connection is
created, and used to access different tables in the same database, are the
tables affected by the second connection visible to other processes as the
changes are made, not masked by the START TRANSACTION on the first
Connection? Thanks.


Frank Natoli wrote:
Quoted text here. Click to load it

Yes, changes may be visible in the first transaction, but only if the
first transaction was initiated with START TRANSACTION READ-COMMITTED or

But the default mode for InnoDB is not this.  That is, if you use START
TRANSACTION with no further arguments, it defaults to REPEATABLE READ
mode.  In this mode, you can see only the state of data at the moment
you started the transaction.  Other changes made by other clients since
you started your transaction are not visible.  That is, until you finish
your transaction and begin a new one.

Bill K.

Site Timeline