v.25.6Improvement
When checking if a KeyCondition matches
When checking if aKeyConditionmatches a continuous range, if the key is wrapped with a non-strict function chain, aConstraint::POINTmay needs to be converted to aConstraint::RANGE. For example:toDate(event_time) = '2025-06-03'implies a range forevent_time: ['2025-06-03 00:00:00', '2025-06-04 00:00:00'). This PR fixes this behavior. #81400 (zoomxi).
Why it matters
Addresses the issue where aKeyCondition involving functions like toDate was incorrectly treated as a single point constraint, leading to incorrect query optimization. This ensures that expressions such as toDate(event_time) = '2025-06-03' are correctly interpreted as a range for event_time, enhancing query accuracy and optimization.How to use it
Users do not need to make any changes. The improved behavior is applied automatically when writing queries involving keys wrapped in non-strict function chains. Queries likeSELECT ... WHERE toDate(event_time) = '2025-06-03' will now correctly use range constraints internally.