NAME
ROLLBACK - 退出当前事务
SYNOPSIS
ROLLBACK [ WORK | TRANSACTION ]
DESCRIPTION 描述
ROLLBACK 回卷当前事务并取消当前事务中的所有更新。
PARAMETERS 参数
- WORK
- TRANSACTION
可选的键字。没有作用。
NOTES 注意
使用 COMMIT [commit(7)] 语句将一次事务成功停止。
如果不在一个事务内部发出 ROLLBACK 不会有问题,但是将抛出一个警告信息。
EXAMPLES 例子
取消所有更改:
ROLLBACK;
COMPATIBILITY 兼容性
SQL 标准只声明了两种形式 ROLLBACK 和 ROLLBACK WORK。否则完全兼容。
SEE ALSO 参见
BEGIN [begin(7)], COMMIT [commit(l)]
#p#
NAME
ROLLBACK - abort the current transaction
SYNOPSIS
ROLLBACK [ WORK | TRANSACTION ]
DESCRIPTION
ROLLBACK rolls back the current transaction and causes all the updates made by the transaction to be discarded.
PARAMETERS
- WORK
- TRANSACTION
- Optional key words. They have no effect.
NOTES
Use COMMIT [commit(7)] to successfully terminate a transaction.
Issuing ROLLBACK when not inside a transaction does no harm, but it will provoke a warning message.
EXAMPLES
To abort all changes:
ROLLBACK;
COMPATIBILITY
The SQL standard only specifies the two forms ROLLBACK and ROLLBACK WORK. Otherwise, this command is fully conforming.
SEE ALSO
BEGIN [begin(7)], COMMIT [commit(l)]