What is the difference between constraints and triggers?
Answer Posted / sairam singh
Both will be used to implement business rules.
Constraints will do memory location to table comparision.
where as triggers will do table to table comparision.
for this triggers will use magic tables(inserted,deleted).
In the order of precedence first Constraints next Triggers,
But performance wise triggers will give best performance
because table to table comparision is faster than memeory
location to table comparision.
| Is This Answer Correct ? | 4 Yes | 3 No |
Post New Answer View All Answers
What are actions, how many types of actions are there, explain with example? : sql server analysis services, ssas
What is key attribute?
What are the disadvantages of indexes?
What are the different methods available under sqlcommand class to access the data?
Can we take the full database backup in log shipping?
What are triggers? How do you invoke a trigger on demand?
What is the difference between the application object and session object?
What do you understand by recursive stored procedures?
What is the maximum number of instances in 32 bit and 64 bit sql server 2012?
What is sql server used for?
What is the difference between MVC and Teir Architecher? Plz explain with Layyered Programming example...? Thanks
Does transparent data encryption provide encryption when transmitting data across the network?
Can we perform backup restore operation on tempdb? : sql server database administration
what happens on checkpoint? : Sql server database administration
What is db stored procedure?