hive多表查询的条件写在join里好还是用子查询?
两个表关联查询,是把条件都写join on里好?
select a.* from a join b on ( a.id = b.id and a.a = 2 and b.c = 3)
还是写成子查询的形式比较快?
select a.* from a join (select b.* from b where b.c = 3) c on (a.id = c.id) where a.a = 2
目前暂无任何回答
- 0 回答
- 0 关注
- 2607 浏览
添加回答
举报
0/150
提交
取消