select month,ranking,song_name,play_pv
from (
select month(fdate) as month,
row_number() over(
partition by month(fdate) 
order by count(t2.song_id) desc) as ranking,
song_name,count(t2.song_id) as play_pv

from song_info as t1 
join play_log as t2 on t1.song_id=t2.song_id
join user_info as t3 on t2.user_id=t3.user_id
where t2.fdate between '2022-01-01' and '2022-12-31' 
and t3.age between 18 and 25 
and t1.singer_name='周杰伦' 
group by month(fdate),song_name
) as t4
where ranking <=3;