select join where执行顺序

select  xxxxx   from t1  join  t2  on t1.sss = t2.dddd where t1.mmm > 3;

先执行 t1 join t2  在执行 where 条件  最后在执行 select xxxx

如果此时select xxx的字段是你重新命名的别名 , 那么按照上面顺序,回报错,报错说这个别名在

t1  t2里面都没找到。

猜你喜欢

转载自chengjianxiaoxue.iteye.com/blog/2283598