Is it possible to use Transactional control statements in
Database ?
Answers were Sorted based on User's Feedback
Answer / ddrema
It's posible and mandatory if you use AUTONOMOUS
TRANSACTION in the TRIGGER.
like this:
CREATE OR REPLACE TRIGGER audit_sal
BEFORE UPDATE OF salary ON employees FOR EACH ROW
DECLARE
PRAGMA AUTONOMOUS_TRANSACTION;
BEGIN
INSERT INTO emp_audit VALUES( :old.employee_id, SYSDATE,
:new.salary, :old.salary );
COMMIT;
END;
/
Is This Answer Correct ? | 2 Yes | 0 No |
Answer / guest
no, it is not possible to use Transactional control
statements in Database Triggers
Is This Answer Correct ? | 0 Yes | 1 No |
What is the difference between hashed file stage and sequential file stage in relates to datastage server?
What do you mean by Correlated subquery in database?
What are the three levels of data abstraction?
What is dbms function?
What is a system concept?
What is view dbms?
How do you performance tune a database?
Explain vdl (view definition language)?
How do I convert a spreadsheet to a database?
Differentiate between ‘delete’, ‘truncate’ and ‘drop’ commands.
What are the four objectives of the selection of a data type?
Explain 4nf?