Manya0407 commented on code in PR #6746:
URL: https://github.com/apache/hive/pull/6746#discussion_r4044268120
##########
hbase-handler/src/test/results/positive/hbase_queries.q.out:
##########
@@ -310,7 +310,7 @@ STAGE PLANS:
alias: hbase_table_1
Statistics: Num rows: 1 Data size: 4 Basic stats: COMPLETE Column
stats: NONE
Filter Operator
- predicate: ((key > 100) and (key < 120)) (type: boolean)
+ predicate: ((key < 120) and (key > 100)) (type: boolean)
Review Comment:
From what I’ve seen, the predicate reordering looks driven by
HiveFilterSortPredicates sorting AND/OR conjuncts by selectivity/cost via
FilterSelectivityEstimator. HIVE-29652 changes range selectivity estimates when
MIN/MAX stats are present, so conjuncts like (key > 100) vs (key < 120) can
swap order in explain output even though semantics stay the same.
The predicate reordering isn’t required for HIVE-29652 itself — it’s a side
effect of updated selectivity feeding existing HiveFilterSortPredicates. I
don’t see a way to avoid it without disabling that optimization or splitting
selectivity logic for sorting vs costing; updating the .q.out files seems like
the right approach, but I’m open to other suggestions if you prefer.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]