一、用distinct 关键字 去掉重复的数据select distinct B from A oder by B显示的结果就是 123456 二、 用group by 关键字 对B字段进行分组select B from A group by B
select distinct A.B from A
select b from agroup by b
select distinct B from A order by B