what is Constraint? How many types of constraints in SQL ?

Answer Posted / m arunachalam

Constraints are used to limit the type of data that can go
into a table.

Constraints can be specified when a table is created (with
the CREATE TABLE statement) or after the table is created
(with the ALTER TABLE statement).

We will focus on the following constraints:

NOT NULL
UNIQUE
PRIMARY KEY
FOREIGN KEY
CHECK
DEFAULT

Is This Answer Correct ?    1 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Explain what is it unwise to create wide clustered index keys?

544


What do you understand by mirroring and mention the advantages of the mirroring?

583


What are the features of Embedded SQL

678


Explain having clause?

530


Give main differences between "Truncate" and "Delete".

582






Explain the properties of subqueries in sql server?

548


Which data type columns are the best candidates for full-text indexing?

604


Explain what is use of dbcc commands?

515


If no size is defined while creating the database, what size will the database have?

548


What are database states in ms sql server?

655


Explain transaction server consistency?

528


How to define the name and server for a new dsn?

549


Can the “if update (colname)” statement be used in a delete trigger?

559


How can I create a report based on a query? : sql server management studio

564


Is candidate a key?

536