---恢复内容开始--- 1.如何进行行列转换 需求: 列转换成行 select a.`user_name`,sum(b.kills) from user1 a join user_kills b on a.id = b.user_id group by a.user_name; -行转换成列 select sum(case when user_name='wukong' then kills end) as 'wukong', sum(case when user_name='zhubajie…