tutorial net
*********WOOOOOOW *********
We're happy to see you're enjoying our races (already 5 pages viewed today)! You can keep checking out by becoming a member of the tutorial net community. It's free!
You will also be able to keep track of your race progress, practice on exercises, and chat with other members.

Join the forum, it's quick and easy

tutorial net
*********WOOOOOOW *********
We're happy to see you're enjoying our races (already 5 pages viewed today)! You can keep checking out by becoming a member of the tutorial net community. It's free!
You will also be able to keep track of your race progress, practice on exercises, and chat with other members.
tutorial net
Would you like to react to this message? Create an account in a few clicks or log in to continue.

Go down
avatar
Admin
Admin
Posts : 207
Join date : 2017-11-11
Age : 33
Location : algeria
http://www.tutorial-net.com

Tutorial SQL - SQL DISTINCT Empty Tutorial SQL - SQL DISTINCT

Tue Apr 10, 2018 10:56 pm
SQL DISTINCT
Using SELECT in SQL allows you to read all data from one or more columns. This command can potentially display duplicate rows. To avoid redundancies in the results simply add DISTINCT after the word SELECT.

Basic command
The basic use of this command is then to perform the following query:

Code:
SELECT DISTINCT my_column
FROM table_name
This query selects the "my_column" field in the "table_name" table, avoiding duplicate returns.

Query for Oracle
For the Oracle Database Management System (DBMS), this query is replaced by the "UNIQUE" command:

Code:
SELECT UNIQUE my_column
FROM table_name
Back to top
Permissions in this forum:
You cannot reply to topics in this forum