What is the Diff b/w Constraints and Trigeer

Answer Posted / saraswathi muthuraman

TO apply business rule we are using Constraints and trigger.

If we have any computation and validation over the
calculated value we have choose "trigger".


Direct validation like the column should not contain null
values then you can choose Constraints.

Constraints : NOT NULL,UNIQUE,PRIMARY KEY,CHECK,REFERENCE

Trigger effected only those row after which trigger applied
but constraint effected all row of table .

Is This Answer Correct ?    24 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is aggregate function in sql?

736


who introduced sql?

752


What is pragma in pl sql?

766


what are the system privileges that are required by a schema owner (user) to create a trigger on a table?

811


What is the difference between distinct and unique in sql?

654






Write a query to find the names of users that begin with "um" in sql?

703


List out the acid properties and explain?

711


how to do backup entire database? : Transact sql

883


Can I learn sql in a week?

753


What is the file extension for sql database?

671


How do you remove duplicate records from a table?

676


Explain the steps needed to create the scheduled job?

749


what is a composite key ? : Sql dba

798


What are the triggers associated with image items?

794


Can we create table inside stored procedure?

696