diff options
Diffstat (limited to 'doc/src/sgml/man7/COMMIT.7')
-rw-r--r-- | doc/src/sgml/man7/COMMIT.7 | 89 |
1 files changed, 89 insertions, 0 deletions
diff --git a/doc/src/sgml/man7/COMMIT.7 b/doc/src/sgml/man7/COMMIT.7 new file mode 100644 index 0000000..ae4ee6a --- /dev/null +++ b/doc/src/sgml/man7/COMMIT.7 @@ -0,0 +1,89 @@ +'\" t +.\" Title: COMMIT +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets vsnapshot <http://docbook.sf.net/> +.\" Date: 2024 +.\" Manual: PostgreSQL 16.2 Documentation +.\" Source: PostgreSQL 16.2 +.\" Language: English +.\" +.TH "COMMIT" "7" "2024" "PostgreSQL 16.2" "PostgreSQL 16.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +COMMIT \- commit the current transaction +.SH "SYNOPSIS" +.sp +.nf +COMMIT [ WORK | TRANSACTION ] [ AND [ NO ] CHAIN ] +.fi +.SH "DESCRIPTION" +.PP +\fBCOMMIT\fR +commits the current transaction\&. All changes made by the transaction become visible to others and are guaranteed to be durable if a crash occurs\&. +.SH "PARAMETERS" +.PP +WORK +.br +TRANSACTION +.RS 4 +Optional key words\&. They have no effect\&. +.RE +.PP +AND CHAIN +.RS 4 +If +AND CHAIN +is specified, a new transaction is immediately started with the same transaction characteristics (see +SET TRANSACTION (\fBSET_TRANSACTION\fR(7))) as the just finished one\&. Otherwise, no new transaction is started\&. +.RE +.SH "NOTES" +.PP +Use +\fBROLLBACK\fR(7) +to abort a transaction\&. +.PP +Issuing +\fBCOMMIT\fR +when not inside a transaction does no harm, but it will provoke a warning message\&. +\fBCOMMIT AND CHAIN\fR +when not inside a transaction is an error\&. +.SH "EXAMPLES" +.PP +To commit the current transaction and make all changes permanent: +.sp +.if n \{\ +.RS 4 +.\} +.nf +COMMIT; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP +The command +\fBCOMMIT\fR +conforms to the SQL standard\&. The form +COMMIT TRANSACTION +is a PostgreSQL extension\&. +.SH "SEE ALSO" +\fBBEGIN\fR(7), \fBROLLBACK\fR(7) |