July 2002
Beginner
424 pages
9h 30m
English
Columns often contain duplicate values, and it’s common to want a result that lists each duplicate only once. If I type Listing 4.6 to list the states where the authors live, the result, Figure 4.6, contains unneeded duplicates. The DISTINCT keyword eliminates duplicate rows from a result.
SELECT state FROM authors; |
state ----- NY CO CA CA NY CA FL |
SELECT DISTINCT columns FROM table;
Read now
Unlock full access