Exam 1z0-082 All QuestionsBrowse all questions from this exam
Question 82

Examine the description of the BOOKS table:

The table has 100 rows.

Examine this sequence of statements issued in a new session:

INSERT INTO books VALUES ('ADV112', 'Adventures of Tom Sawyer', NULL, NULL);

SAVEPOINT a;

DELETE FROM books;

ROLLBACK TO SAVEPOINT a;

ROLLBACK;

Which two statements are true? (Choose two.)

    Correct Answer: A, D

    The sequence of SQL statements involves inserting a row, creating a savepoint, deleting from the table, rolling back to the savepoint, and performing a final rollback. The second ROLLBACK command does nothing because rolling back to the savepoint 'a' undoes the DELETE operation but does not commit or finalize the changes from before the savepoint. The first ROLLBACK command undoes the DELETE operation, restoring the previous state, but does not change the INSERT operation. Therefore, the second ROLLBACK command would undo the entire transaction and also undo the INSERT operation, leaving the table in its original state before any operations occurred.

Discussion
you1234Options: CD

C & D is correct one

Ekos

i agree

Guhborges

I agree, C & D

yukclam9

to me the insert does not make sense. why we are inserting characters to a date column?

LrnsTgh

πŸ˜‚ LOL. very good eyes

Reiwardy

That’s why they are trying to rollback the stuff.

Oracle2020Options: CD

I agree C, D is correct

ErickZcOptions: CD

The correct answer is C,D I Tested it in my local database 19.11.0.0.0 COUNT(*) ---------- 10 1 row selected. 1 row created. Savepoint created. 11 rows deleted. Rollback complete. COUNT(*) ---------- 11 1 row selected. Rollback complete. COUNT(*) ---------- 10 1 row selected.

feixiang

the SQL INSERT is wrong

musafirOptions: CD

C D is correct

mamaduOption: A

There is only one correct answer here A.

mamadu

the first rollback finishes the DELETE transaction, so no transaction open for second rollback.

LeandroHPNOptions: CD

C , D is correct.

algerianphoenixOption: D

Even though it is asked for "two" correct answers, I only found D as correct, the others make no sense to me, especially the SQL INSERT itself is wrong.