[SQL] What are the top 10 Pop songs based on the engagement rate?
Tables: song_df, fact_df
Use the tables to find the 10 Pop songs with the highest engagement rate.
这道题的核心是先把事实表和歌曲表按 <code>Song_ID</code> 关联起来,再筛选出流派包含 <code>Pop</code> 的歌曲,最后根据互动率进行排序并取前 10 名。通常互动率可以由点赞、分享、评论等行为与播放量共同计算,因此要先明确题目给出的字段含义,再在聚合后计算每首歌的综合表现。实现时重点是连接、过滤、分组聚合和排序,适合考察 SQL 基础查询能力与对指标口径的理解。
正文完