Exhibit. Which statement causes more undo generation?
A.
SELECT * FROM emp;
B.
DELETE FROM emp WHERE empno=7934;
C.
UPDATE emp SET comm=400 WHERE empno=7844;
D.
INSERT INTO emp
VALUES(7999,’JHON’,’CLERK’,7782,’10-MAY-83′,1500,NULL,10);
Exhibit. Which statement causes more undo generation?
Exhibit. Which statement causes more undo generation?
A.
SELECT * FROM emp;
B.
DELETE FROM emp WHERE empno=7934;
C.
UPDATE emp SET comm=400 WHERE empno=7844;
D.
INSERT INTO emp
VALUES(7999,’JHON’,’CLERK’,7782,’10-MAY-83′,1500,NULL,10);
B
Can someone explain the logic on why the answer is B
• Deletes are expensive for rollback segments; they need to store the actual row itself. If you can use TRUNCATE instead, performance is improved.