Mysql去除重复

常用的有两种方法,第一种就是select distinct name from table。但是有时候我们要返回多个字段时就用第二种方法select *, count(distinct name) from table group by name

原文地址:https://www.cnblogs.com/jiayongchao/p/4562939.html