ALLInterview.com :: Home Page
 Advertise your Business Here     
Browse  |   Placement Papers  |   Company  |   Code Snippets  |   Certifications  |   Visa Questions
Post Question  |   Post Answer  |   My Panel  |   Search  |   Articles  |   Topics  |   Errors
   Testimonials Refer this Site  Refer This Site to Your Friends  Site Map  Contact Us      
   
 
Categories >> Software >> Databases >> MySQL
 


   

 

Question What is the difference between primary and unique key
 Question Asked In Companies :: CSC,     < I also faced this Question! >
 Question Submitted By :: kamaltimalsina012
  Answer Posted By  
 
Answer
Primay key restrict the duplicacy in the records and does
not accept null value or there are only one primary key in
a table

Unique constraint also restict the duplicacy but it accept
the null value one or more then one. We can apply unique
constraint more than one column

Is This Answer Correct ?    2 Yes 2 No


 
  ashish asthana
 
View All Answers
 
 
Please Help Members By Posting Answers For Below Questions
 
 Question Views   Select
 
Explain the architecture models of SQL Server? 888
In a property booking section want a query to check that property is booked from StartDate to EndDate.Booking Table field are given id proerty_id start_date checkout_date no_of_visitor booking date status Waiting yours answer.. Thanks In Advance... 1193
What are the critical issues you have resolved in your company 699
Can u give the example by taking an unnormalized table and make that 1nf and then 25nf, and then 3 nf? 3048
How can you get your MySQL root password, if you lost it? 1118
1)for snapshot replication which agents used? 2)for Transcation replication which agents used? 3)for merge replciation which agents used? 681
explain GROUPBY & HAVING clause with examples. 830
How can you move the master database 537
I want to insert userid of a customer,order time,etc in a table called ordermaster with orderid as primary key.Same time the product codes and required quantities (a1,2 and a2 4 and so on)inserted in another table orderdetails with same orderid reference.How the code will be in JSP using MySQL? 505
Table - Products has number of products as below Productid ProductName 1 iPhone 2 iPad 3 BlackBerry Table - SalesPersonProduct has the below records Salespersonid productid S1 1 S1 2 S1 3 S2 1 S3 2 Write a SQL query that returns the total number of sold products 1292
What is striped backup 821
how to get only updated, deleted , inserted records after certain interval time in mysql with out using triggers... 746
How to set the time zone for MySQL to particular country time? 1719
How to enable or disable a row of a table using MySQL in struts? 2087
HOW TO FIND display the total number of weeks in the year of 1998 IN EMP TABLE 723
E-Mail New Answers        Answer Selected Questions