GeekInterview.com
  I am new, Sign me up!
 
GeekInterview.com  >  Interview Questions  >  Database  >  MYSQL
Go To First  |  Previous Question  |  Next Question 
 MYSQL  |  Question 44 of 49    Print  
what is difference between candidate key and primary key

  
Total Answers and Comments: 3 Last Update: December 24, 2008     Asked by: suresh.kalyadapu 
  
 Sponsored Links

 
 Best Rated Answer
Submitted by: shankcool
 
A candidate key is a unique identifier that could be used as a primary key, which when you choose the primary key, the rest will then just be data fields

Above answer was rated as good by the following members:
softviji, kushks
June 02, 2008 08:18:52   #1  
shankcool Member Since: June 2008   Contribution: 1    

RE: what is difference between candidate key and primary key
A candidate key is a unique identifier that could be used as a primary key which when you choose the primary key the rest will then just be data fields
 
Is this answer useful? Yes | NoAnswer is useful 1   Answer is not useful 1Overall Rating: -N/A-    
October 17, 2008 02:59:27   #2  
basabdutta9 Member Since: October 2008   Contribution: 1    

RE: what is difference between candidate key and primary key
Primary key is the unique key to identify a record and Candidate key is composed of one or more than one key to make it unique.
 
Is this answer useful? Yes | No
December 24, 2008 00:03:54   #3  
veerbahadur Member Since: December 2008   Contribution: 4    

RE: what is difference between candidate key and primary key
Any attribute that is uniquely identify a row in a table is candidate key for the table. We select one of the candidate key as Primary key. All candidate keys which are not chosen as primary key are Alternate keys. The key which uniquely identify the rows of the table and which is made up of more than one attribute is called Composite key. Generally a candidate key becomes the primary key of the table. If the table has more than one candidate key one of them will become the primary key and the rest are called alternate keys.
 
Is this answer useful? Yes | NoAnswer is useful 1   Answer is not useful 0Overall Rating: +1    


 
Go To Top


 Sponsored Links

 
About Us -  Privacy Policy -  Terms and Conditions -  Contact -  Ask Question -  Propose Category -  Site Updates 

Copyright © 2005 - 2009 GeekInterview.com. All Rights Reserved

Page copy protected against web site content infringement by Copyscape