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

Why do we use procedures?

750


What is the difference between an inner join and an outer join?

770


Can we rollback truncate?

774


What is the default isolation level in sql server? : Transact sql

798


What are the operators used in select statements?

828


what is “go” in t-sql? : Transact sql

854


How can I tell if sql is running?

819


what is a control file ? : Sql dba

810


Why do we go for stored procedures?

783


How to revise and re-run the last sql command?

888


How to convert comma separated string to array in pl/sql?

881


how to create a new table in mysql? : Sql dba

757


What are % type and % rowtype?

813


How can we make an if statement within a select statement?

787


what is clause? : Sql dba

806