在impala错误中创建查询时使用“ with”错误

时间:2019-01-13 16:43:01

标签: impala

我在下面有一个查询,要求在黑斑羚中对其进行测试:

WITH 
final_table_temp AS
(select bank_cd, region_cd, product_cd, date_pull
from v201811_pas_ods_rates),
related_pas_ods_rates_count AS
    (select bank_cd, count(*) as ct from final_table_temp group by bank_cd)
create table fina_table partitioned by (date_pull) stored as parquet
as      
select t.* 
    from final_table_temp t
    inner join [shuffle] related_pas_ods_rates_count h on h.bank_cd=t.bank_cd
    where  t.bank_cd is not null
    and h.ct <=1000000
    order by t.bank_cd;

注意:此查询在impala-shell中失败,但是如果我删除了 create table final_table partitioned by (date_pull) stored as parquet as 选择查询实际上有效。

Impala在创建查询中是否支持“ with”?如果是,该如何修改查询?

非常感谢您。

0 个答案:

没有答案