Differences between UNIQUE and DISTINCT in select statements

Answer Posted / prabha

Distinct:
Its gives only the non duplicate values in a database table.
Unique:
The UNIQUE constraint uniquely identifies each record in a
database table.its similar to primary key.these values
cannot be repeated.

Is This Answer Correct ?    3 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Mention what does the hierarchical profiler does?

549


Why truncate is faster than delete?

552


How do I count rows in sql?

551


What is the use of nvl function?

607


Which one is better subquery or joins?

547






can a stored procedure call itself or recursive stored procedure? How much level sp nesting is possible? : Sql dba

521


What is meant by temporal data?

532


what is a join? : Sql dba

556


What is sql lookup?

502


How do you use a while loop in pl sql?

528


What is the difference between the repeatable read and serializable isolation levels? : Transact sql

526


Why do we create stored procedures & functions in pl/sql and how are they different?

498


Who developed sql?

561


What does the base_object_type column shows in the user.triggers data dictionary view?

565


what are the 'mysql' command line arguments? : Sql dba

641