[ https://issues.apache.org/jira/browse/HIVE-17465?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Vineet Garg updated HIVE-17465: ------------------------------- Status: Patch Available (was: Open) > Statistics: Drill-down filters don't reduce row-counts progressively > -------------------------------------------------------------------- > > Key: HIVE-17465 > URL: https://issues.apache.org/jira/browse/HIVE-17465 > Project: Hive > Issue Type: Bug > Components: Physical Optimizer, Statistics > Reporter: Gopal V > Assignee: Vineet Garg > Attachments: HIVE-17465.1.patch > > > {code} > explain select count(d_date_sk) from date_dim where d_year=2001 ; > explain select count(d_date_sk) from date_dim where d_year=2001 and d_moy = > 9; > explain select count(d_date_sk) from date_dim where d_year=2001 and d_moy = 9 > and d_dom = 21; > {code} > All 3 queries end up with the same row-count estimates after the filter. > {code} > Map Operator Tree: > TableScan > alias: date_dim > filterExpr: (d_year = 2001) (type: boolean) > Statistics: Num rows: 73049 Data size: 82034027 Basic > stats: COMPLETE Column stats: COMPLETE > Filter Operator > predicate: (d_year = 2001) (type: boolean) > Statistics: Num rows: 363 Data size: 4356 Basic stats: > COMPLETE Column stats: COMPLETE > > Map 1 > Map Operator Tree: > TableScan > alias: date_dim > filterExpr: ((d_year = 2001) and (d_moy = 9)) (type: > boolean) > Statistics: Num rows: 73049 Data size: 82034027 Basic > stats: COMPLETE Column stats: COMPLETE > Filter Operator > predicate: ((d_year = 2001) and (d_moy = 9)) (type: > boolean) > Statistics: Num rows: 363 Data size: 5808 Basic stats: > COMPLETE Column stats: COMPLETE > Map 1 > Map Operator Tree: > TableScan > alias: date_dim > filterExpr: ((d_year = 2001) and (d_moy = 9) and (d_dom = > 21)) (type: boolean) > Statistics: Num rows: 73049 Data size: 82034027 Basic > stats: COMPLETE Column stats: COMPLETE > Filter Operator > predicate: ((d_year = 2001) and (d_moy = 9) and (d_dom = > 21)) (type: boolean) > Statistics: Num rows: 363 Data size: 7260 Basic stats: > COMPLETE Column stats: COMPLETE > {code} -- This message was sent by Atlassian JIRA (v6.4.14#64029)