+3 votes
in Class 12 by kratos

Mr. Krishnaswami is working on a database and has doubt about the concept of SAVEPOINT in a transaction. Write down the meaning of SAVEPOINT and provide a simple example considering yourself as an online web support executive.

1 Answer

+6 votes
by kratos
 
Best answer

SAVEPOINT is a point in a transaction, up till which all changes have been saved permanently'

EXAMPLE:

mysql>

mysql> CREATE TABLE Books -> ( -> BookID SMALLINT NOT NULL PRIMARY KEY, BookTitle VARCHAR(60) NOT NULL, CopyrightYEAR NOT NULL)

ENGINE=INNODB;

mysql> START TRNSACTION;

mysql> INSEKI INTO Books VALUES (103,'Opera', 1966);

mysql> INSERT INTO Books VALUES (104,'Sql Sewer', 1932);

...