What is Key in SQl-Server?

Unique Key
  • The field must be unique within it’s Column.

    Primary Key

  • A Combination of unique & not null.

  • A table has Only one Primary Key.

    Foreign Key

  • Define relationship between two Table.

  • Either one to one, one to many, many to many
    Candidate Key

  • A table may have more than one combination of columns that could uniquely identify the rows in a Table, each combination is a Candidate Key.
  • A candidate Key is one that can identify each rows of a table uniquely.

Leave a Reply

Your email address will not be published. Required fields are marked *

1 + 8 =

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code class="" title="" data-url=""> <del datetime=""> <em> <i> <q cite=""> <strike> <strong> <pre class="" title="" data-url=""> <span class="" title="" data-url="">