And if the user clicks UNDO, do a ROLLBACK?
Edit: Of course, if anything goes wrong before the COMMIT, you loose the transaction.
Database transaction are like try/except blocks - designed to clean up unexpected situations instantly, not as a state mechanism.
And if the user clicks UNDO, do a ROLLBACK?
Edit: Of course, if anything goes wrong before the COMMIT, you loose the transaction.