如何将此Microsoft SQL查询转换为MySQL查询?

时间:2016-10-29 07:34:35

标签: mysql sql-server

我使用此查询从Microsoft SQL Server表中获取特定结果,但现在我需要将此查询转换为MySQL查询。我不知道该怎么做。

SELECT TOP 3 COUNT(Item1) AS ITEM_COUNT,Item1
FROM [cloths_DB].[dbo].[Suggetion_DB]
WHERE [Type] = 'Adidas'  and [Age]='25'
GROUP BY Item1
ORDER BY ITEM_COUNT DESC

1 个答案:

答案 0 :(得分:0)

SELECT COUNT(Item1) AS ITEM_COUNT,Item1
FROM Suggetion_DB
WHERE Type = 'Adidas'  and Age='25'
GROUP BY Item1
ORDER BY ITEM_COUNT DESC
limit 3