MySQL - COMMIT and ROLLBACK in MySQL

COMMIT and ROLLBACK in MySQL

A transaction in MySQL is a set of SQL statements written to perform a specific task. When the transaction is COMMIT, the changes made are saved permanently. ROLLBACK cancels all changes and reverts back the transaction to its state before COMMIT.

It is necessary to commit work in case of system crash.

COMMIT and ROLLBACK in MySQL

COMMIT : Commit statement commits the current transaction, which means making the changes permanent. A transaction may involve update and or delete and or insert statements.

ROLLBACK : Rollback statement rolls back the present transaction, which means cancelling a transaction’s changes.

The statement SET AUTOCOMMIT enables or disables the committing transactions automatically for the current session.
MySQL - ALTER command to add and drop INDEX in MySQL
ALTER command to add and drop INDEX in MySQL - An index in MySQL can be added using ALTER statement in multiple ways....
MySQL Connection- Describe MySQL Connection using PHP Script.
MySQL Connection - Establishing connection to MySQL database using PHP can be done by using mysql_connect(server,user,passwd,new_link,client_flag)....
MySQL - What is MySQL?
MySQL defined- MySQL can be considered as a relational database management system.
Post your comment