Difference between Primary key and unique key?

Answers were Sorted based on User's Feedback



Difference between Primary key and unique key?..

Answer / deepali b. baviskar

Unique key can be NULL but Primary key couldn't be NULL.

Is This Answer Correct ?    11 Yes 0 No

Difference between Primary key and unique key?..

Answer / sraboni mondal

primary key is a key which is totally unique key and unique
has null values

Is This Answer Correct ?    0 Yes 1 No

Difference between Primary key and unique key?..

Answer / sohini ghosh

In RDBMS, a unique key can uniquely identify each row in a
table, and is closely related to the Super key concept. A
unique key comprises a single column or a set of columns.it
can be null.


A primary key is a special case of unique key. Primary keys
may consist of a single attribute or multiple attributes in
combination.It can't be null..

Is This Answer Correct ?    0 Yes 2 No

Difference between Primary key and unique key?..

Answer / keerthi

primary key is a field that can serve as unique identifier in table.ex:customer id.

Is This Answer Correct ?    1 Yes 4 No

Post New Answer

More Core Java Interview Questions

in a constructor what happen if u call super and this in the same class? i know that it is not possible to call both in the same one? if we call what will happen?

10 Answers   ITC Infotech,


What about main thread in java?

0 Answers  


This is my code i have a doubt class ab implements a,b { public void add() { System.out.println("Hi") } } interface a { public void add(); } interface b { public void add(); } in this code i have two interface implemented in the class has same method.just i want to know which method of interface implemented in the class. interface a or interface b? confused me .

3 Answers  


Can we override the overloaded method?

0 Answers  


Can you explain inner class.

0 Answers  






How do you write a conditional statement?

0 Answers  


Consider that class classA, abstract class classB, and final classC have been defined.Which one of the following is correct? 1. classA extends classC implements classB 2. class A extends classB, classC 3. classA extends classB 4. classB implements classC

2 Answers  


what is the difference between @include page and @include file

2 Answers  


What is meant by Encapsulation? Can you write a class to explain encapsulation?

8 Answers   Ness Technologies,


explain Anonynous inner class?

6 Answers   TCS,


What is meant by inheritance and what are its advantages?

0 Answers  


Differece between class and generic class?

0 Answers   Tech Mahindra,


Categories