Geeks Talk

Prepare for your Next Interview




Unique with NotNull??

This is a discussion on Unique with NotNull?? within the SQL Server forums, part of the Databases category; Primary key is Clustered Index and not allows null value. Unique key is NonClustered Index allows one Null value Can I Define Unique key + Not Null is Equal to Primary ...


Go Back   Geeks Talk > Databases > SQL Server

Register FAQ Members List Calendar Mark Forums Read
  #1 (permalink)  
Old 06-08-2007
Contributing Member
 
Join Date: Jun 2007
Location: Bangalore
Posts: 32
Thanks: 3
Thanked 20 Times in 5 Posts
vcyogi is on a distinguished road
Unique with NotNull??

Primary key is Clustered Index and not allows null value.
Unique key is NonClustered Index allows one Null value

Can I Define Unique key + Not Null is Equal to Primary key ????
Reply With Quote
Sponsored Links
  #2 (permalink)  
Old 06-08-2007
Junior Member
 
Join Date: May 2007
Posts: 16
Thanks: 0
Thanked 3 Times in 3 Posts
SQLTweety is on a distinguished road
Re: Unique with NotNull??

Quote:
Can I Define Unique key + Not Null is Equal to Primary key ????
Yes, Unique + NOT NULL is equivalent to primary key on a table ,though not explicitly declared. U can always use this column to retrieve a unique row from given table.


HTH

Regards,
Reply With Quote
  #3 (permalink)  
Old 06-08-2007
Contributing Member
 
Join Date: May 2007
Location: bangalore
Posts: 65
Thanks: 3
Thanked 8 Times in 6 Posts
hari.nattuva is on a distinguished road
Re: Unique with NotNull??

I agreed with above answer given by one of our forum member.....
Reply With Quote
Reply

  Geeks Talk > Databases > SQL Server


Thread Tools
Display Modes


Similar Threads

Thread Thread Starter Forum Replies Last Post
difference bet unique and distinct smitai Oracle Certification 2 06-18-2007 04:00 AM
Easy RSS Content Generator is an easy-to-use program for creating new unique content JobHelper Geeks Lounge 0 05-09-2007 11:50 AM
Actual Window Menu is the unique extension of standard window menu that provides adva JobHelper Geeks Lounge 0 04-25-2007 08:30 AM
How to find the unique id of mails through code priya1985 Scripting 0 02-08-2007 03:30 AM
Usage of Unique Index RyanJames Oracle 2 10-13-2006 07:00 PM


All times are GMT -4. The time now is 01:47 PM.


Powered by vBulletin® Version 3.6.8
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.1.0
Copyright © 2008 GeekInterview.com. All Rights Reserved