MYSQL明显不起作用23

时间:2017-02-22 18:18:00

标签: mysql

我的查询如下

select distinct TopName, Occurrences, State, Year
From topbabynamesbystate
where Gender = "F" and State = "WA" and (year >= 2000)
order by Occurrences desc
limit 3
名称emily仍然在数据集中显示两次。

1 个答案:

答案 0 :(得分:0)

您可能想要的是

  

SELECT DISTINCT TopName   来自topbabynamesbystate AS t1   INNER JOIN TopName AS t2 ON t1.TopName = t2.TopName   性别=" F"   AND St​​ate =" WA"   AND(年> = 2000)