select distinct 的问题?
select distinct firstname,userid from lawyer where vn='english' and letter='d' order by userid asc
我想搜索出来的firstname不重复,但按上面的句子,出来还是重复的。
select distinct firstname from lawyer where vn='english' and letter='d'
但是这样是可以的。
但我要求搜索出来的字段不止有firstname,还要有userid,sex.......字段,要怎么改呀?
急,谢谢了