~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to docs/savepoints.rst

  • Committer: Brian Aker
  • Date: 2010-12-27 19:16:17 UTC
  • mto: This revision was merged to the branch mainline in revision 2036.
  • Revision ID: brian@tangent.org-20101227191617-b1jesi0g2okc06nj
Improvement for decimal in encapsulation.

Show diffs side-by-side

added added

removed removed

Lines of Context:
5
5
 
6
6
        SAVEPOINT identifier
7
7
 
8
 
This sets a savepoint that can be returned to in the current transaction. The "identifier" is the name given to the new savepoint. If the identifier has already been used then the original identifier is replaced. Example:
9
 
 
10
 
.. code-block:: mysql
11
 
 
12
 
     SAVEPOINT A;
13
 
     INSERT INTO t1 values (1);
14
 
     SAVEPOINT A;
15
 
     INSERT INTO t1 values (2);
16
 
     ROLLBACK TO SAVEPOINT A;
17
 
 
18
 
Will only roll back the second insert statement.
 
8
This sets a savepoint that can be returned to in the current transaction. The "identifier" is the name given to the new savepoint. If the identifier has already been used then the original identifier is replaced.