版本:3.2.1
我创建了一个天级别的物化视图,然后查询时候,也是指定这一天。但是查询没有走物化视图。有大佬知道怎么回事吗?
物化sql:
CREATE MATERIALIZED VIEW v_rpt_ads_show_diagnose_filter_stat_inc_h_20231219 PARTITION BY str2date(dayno,’%Y%m%d’) DISTRIBUTED BY hash(biztype) PROPERTIES ( “force_external_table_query_rewrite” = “true” ) AS select dayno,hour,biztype ,count(1) from dh_hive_catalog_hms.ad_da.rpt_ads_show_diagnose_filter_stat_inc_h where dayno=20231219 group by dayno,hour,biztype;
我的查询语句:
select dayno,hour,biztype ,count(1) from dh_hive_catalog_hms.ad_da.rpt_ads_show_diagnose_filter_stat_inc_h where dayno=20231219 group by dayno,hour,biztype;
explain: