select a.user_name, b.skill, c.skill
from user1 as a inner join user_skills as b on a.id = b.user_id and b.skill = '念经'
inner join user_skills as c on b.user_id = c.user_id and c.skill = '变化'
where b.skill_level > 0 and c.skill_level > 0;
这个语法含义能一步一步解读一下吗
首先a与b关联产生结果集这个结果集中满足的条件的是技能是念经,然后将这些结果集与c表关联进一步得到技能是变化的结果集,即这个SQL语句是为了得到既有念经技能又有变化技能的取经人