Table of ContentsPreviousNext

Please, note, that Ispirer SQLWays 6.0 is no longer supported and provided to clients.
You can try out automated conversion of databases and applications with Ispirer Toolkit for free. Download free trial.
Check out the relevant toolkit documentation.
Ispirer SQL Server to Oracle Migration overview.

Ispirer SQLWays Database Migration Software

COMMIT Statement

For explicitly end of transactions you can use a COMMIT statement. A COMMIT statement guarantees that all the transaction's modifications are made in the permanent part of the database. A COMMIT also frees resources, such as locks, used by the transaction.

TABLE 49. COMMIT Statement
Microsoft SQL Server
COMMIT [ TRAN [ SACTION ]               
[ transaction_name | 
@tran_name_variable ] ] 
Marks the end of a successful implicit or explicit transaction. If COMMIT is defined with transaction name or variable, then Microsoft SQL Server closes a user-defined transaction.
If @@TRANCOUNT is 1, COMMIT TRANSACTION makes all data modifications performed since the start of the transaction a permanent part of the database and decrements @@TRANCOUNT to 0. If @@TRANCOUNT is greater than 1, COMMIT TRANSACTION decrements @@TRANCOUNT only by 1.
When it is used in nested transactions, it commits the inner transactions, which do not free resources or make their modifications permanent. The data modifications are made permanent and resources freed only when the outer transaction is committed. Each COMMIT TRANSACTION is issued when @@TRANCOUNT is greater than 1 simply decrements @@TRANCOUNT by 1. When @@TRANCOUNT is finally decremented to 0, the entire outer transaction is committed. Because transaction_name is ignored by SQL Server, issuing a COMMIT TRANSACTION referencing the name of an outer transaction when there are outstanding inner transactions only decrements @@TRANCOUNT by 1.
[COMMENT 'text'] 
The COMMIT statement explicitly makes permanent any changes made to the database during the current transaction.
COMMENT keyword specifies a comment to be associated with the current transaction and is typically used with distributed transactions. The text must be a quoted literal no more than 50 characters long.

Table of ContentsPreviousNext
Copyright 1999-2023 Ispirer Systems.
Ispirer and SQLWays are registered trademarks. All other product names may be trademarks of the respective companies.
All rights reserved.