日期:2014-05-16 浏览次数:20473 次
?可以使用distinct命令 来取消查询结果的重复行
如下:没有使用distinct 命令
SQL> select deptno from scott.emp;
DEPTNO
----------
20
30
30
20
30
30
10
20
10
30
20
30
20
10
已选择14行。
?使用了distinct命令后的效果:
SQL> select distinct deptno from scott.emp;
DEPTNO
----------
30
20
10
?