1.耗时 全查询 > 部分查询 > 子查询
select * from a inner join b ...
select b.x,b.y from a inner join b..
select (...) x,(...) y from a
2.耗时 原sql关联查询 > 查询条件子查询
select 1 from A where 'req' = (select b.y from B where B.x = A.x)
select 1 from A where A.x = (select B.x from B where B.y = 'req')