Can i use Commit inside the Trigger? Suppose i use commit
what will be happy (it's complied /executed/work)
Answer Posted / saraswathi muthuraman
Trigger will be compiled. while execution r error will occur.
To avoid this you can use PRAGMA autonomus_transaction
example :
create or replace trigger emp_test_trig
after update on emp_test
for each row
declare
PRAGMA autonomus_transaction;
begin
insert into dep_test values(100,:new.emp_id);
commit;
end;
/
Is This Answer Correct ? | 18 Yes | 0 No |
Post New Answer View All Answers
what is view? : Sql dba
how to check server status with 'mysqladmin'? : Sql dba
What is sql key?
Difference between truncate, delete and drop commands?
What information is needed to connect sql*plus an oracle server?
What are aggregate functions in sql?
Is sql a backend language?
When you have to use a default "rollback to" savepoint of plvlog?
What are the types pl/sql code blocks?
What is server name sql?
How do I create a memory optimized filegroup?
What is dialect in sql?
What is sql integrity?
What is before and after trigger?
State some properties of relational databases?