which will fire first ? Trigger or Constraint
Answer Posted / radha sri seshu.kolla
I THINK TRIGGER FIRES FIRST, BCZ WHEN U WRITE A TRIGGER
LIKE 'BEFORE INSERT ON EMP' EVENT. THIS TRIGGER WILL FIRE
IMMEDEATELY BEFORE THE DATA IS ABOUT TO INSERT IN THE
TABLE.WHERE AS IN THE CASE OF CONSTRAINTS, WHEN YOU INSERT
THE DATA,THE DATA GOES FOR CONSTRAINT VALIDATION THEN THE
DATA WILL BE REJECTED(IF THE DATA VIOLATES THE CONSTRAINT
RULE). I AM NOT 100% SURE. THIS IS JUST MY IMAGINATION.
| Is This Answer Correct ? | 11 Yes | 5 No |
Post New Answer View All Answers
How to get help at the sql prompt?
What is the difference between inner join and outer join?
What is sql*loader and what is it used for?
Mention what are the benefits of pl/sql packages?
What is rename command in sql?
What is the requirement of self-join?
What is compiled query?
What is database sql?
What are the different schemas objects that can be created using pl/sql?
Is there any restriction on the use of union in embedded sql?
How can I get the number of records affected by a stored procedure?
Can we want to pass a parameter payroll_id to this external pl/sql function, how do we do it?
How do I add a primary key to a table?
what does it mean to have quoted_identifier on? : Sql dba
Can a view be mutating? If yes, then how?