Hi I want to query table_a by different where clause as follow select * from ( select col1, count(1) from table_a where col2 ='xx' group by col1 union all select col1, count(1) from table_a where col2 ='xx' group by col1 union all select col1, count(1) from table_a where col2 ='xx' group by col1 ) I found the total jobs is 4, is there any optimiztion? I think it should scan table_a once and only one job
- hive union all same table zhangjp
- RE: hive union all same table zhangjp