Skip to main content
Search type Search syntax
Tags [tag]
Exact "words here"
Author user:1234
user:me (yours)
Score score:3 (3+)
score:0 (none)
Answers answers:3 (3+)
answers:0 (none)
isaccepted:yes
hasaccepted:no
inquestion:1234
Views views:250
Code code:"if (foo != bar)"
Sections title:apples
body:"apples oranges"
URL url:"*.example.com"
Saves in:saves
Status closed:yes
duplicate:no
migrated:no
wiki:no
Types is:question
is:answer
Exclude -[tag]
-apples
For more details on advanced search visit our help page
Results tagged with
Search options answers only not deleted user 993

A mechanism for committing a consistent set of changes into a database atomically.

6 votes

Behavior of transactions on multiple connections

More details can be found in MariaDB and MySQL docs: SET TRANSACTION Transaction Isolation Levels Consistent Nonlocking Reads which basically sums up to: What one transaction is writing, other transactions … Not before the one transaction commits. When a transaction is writing something to the database, there is no guarantee that the write will persist. …
ypercubeᵀᴹ's user avatar
3 votes
Accepted

MySQL Insert into two tables using new IDs

After your query runs, you'll have a set of copied rows (with configid=41) and an identical set of pasted rows (except for the configid=76 and the auto-created id). Since, these ids are not known in …
ypercubeᵀᴹ's user avatar
26 votes
Accepted

Deferrable unique index in postgres

So the unique partial index (and the implicit constraint it implements) will be checked at every statement (and in fact after every row insert/update in current implementation), not at the end of transaction
ypercubeᵀᴹ's user avatar
6 votes

Is a dropped (or altered) function still available inside already opened transactions?

Meaning, that - in any isolation level - when transaction 2 modifies or deletes the function, transaction 1 is oblivious to it and still uses the old version of the function. … Any changes to the function become visible only after the transaction commits and only to transactions that start after that commit. …
ypercubeᵀᴹ's user avatar
5 votes
Accepted

The finer points of writers locking each other out under the snapshot isolation levels

A transaction always gets an exclusive lock on any data it modifies, and holds that lock until the transaction completes, regardless of the isolation level set for that transaction. … When a data row meets the update criteria, the snapshot transaction verifies that the data row has not been modified by a concurrent transaction that committed after the snapshot transaction began. …
16 votes
Accepted

ROLLBACK doesn't work after INSERT INTO newly created destination table

-- (at this point the previous transaction is done.) … -- At this point there's no transaction context START TRANSACTION ; -- starts a new transaction INSERT INTO `customers__20150119_14_08_20` SELECT * FROM `customers` ; COMMIT ; -- …
ypercubeᵀᴹ's user avatar