Click below for Step by Step and Interview Q & A (dotnetinter) wrote,
Click below for Step by Step and Interview Q & A

Can we insert NULL’s in to UNIQUE key ? ( SQL Server interview questions with answers)

This question was asked in TCS Mumbai for fresher level position. Below goes the answer  for the same.

The whole point about unique keys is to have unique value. So it treats NULL has one the values and allows you to insert one NULL value (stressing it one NULL value) in to the table.

Below is a nice SQL Server interview question video created by which talks about difference between UNIQUE Key and Primary Key

Tags: csharp interview questions, it interview questions with answers, programming interview questions, sql interview answers, sql server interview questions, unique keys and null, unique vs primary key

  • Stored Procedure in SQL Server.

    Stored Procedure in SQL Server Stored Procedure is collection of Sql code that can be saved under a name in SSMS(Sql Server Management Studio).…

  • SQL Server: - Extended Events

    What is Extended Events? SQL Server Extended Events helps the database administrator to collect the information necessary to identify performance…

  • SQL Server - Stored Procedure

    In this article we will understand what is the use and why do we need Stored Procedure. What is Stored Procedures? A stored Procedure is a set of…

  • Post a new comment


    Anonymous comments are disabled in this journal

    default userpic

    Your reply will be screened

    Your IP address will be recorded