Contents Index Deleting rows Making changes permanent

ASA Getting Started
  Updating the Database

Grouping changes into transactions


Adaptive Server Anywhere expects you to group your commands into transactions. You commit a transaction to make changes to your database permanent. When you alter your data, your alterations are not made permanent right away. Instead, they are stored in your transaction log and are made permanent when you enter the COMMIT command.

Knowing which commands or actions signify the start or end of a transaction lets you take full advantage of transactions.

Starting transactions 

Transactions start with one of the following events:

Completing transactions 

Transactions complete with one of the following events:

Options in Interactive SQL 

Interactive SQL provides you with two options which let you control when and how transactions end:

If you are using a data source 
By default, ODBC operates in autocommit mode. Even if you have set the AUTO_COMMIT option to OFF in Interactive SQL, ODBC's setting will override Interactive SQL's. You can change ODBC's setting using the SQL_ATTR_AUTOCOMMIT connection attribute. ODBC autocommit is independent of the CHAINED option.

Adaptive Server Anywhere also supports Transact-SQL commands, such as BEGIN TRANSACTION, for compatibility with Sybase Adaptive Server Enterprise.

For further information, see An overview of Transact-SQL support.


Making changes permanent
Canceling changes
Transactions and data recovery

Contents Index Deleting rows Making changes permanent