表包含(PID,玩家,級別,月,季)從查詢中使用結果子查詢返回意外的結果
我試圖創建一個顯示每個球員,他們打出這幾個月的查詢,什麼他們的排名是那個月以及那個月有多少玩家。
這裏是我想什麼是每月0.1我如何得到這個正確
SELECT name as Name
, month as Month
, rank as Rank
, (select count(*) from results where month='month') as TotalPlayers
FROM `results`
WHERE season=CurrentSeason
and name="Player"
我的子查詢返回結果?
請提供一些示例數據和期望的輸出 – 2013-04-21 18:30:27