rluvaton opened a new issue, #23920: URL: https://github.com/apache/datafusion/issues/23920
After this is merged: - #23807 we now have a new property `strictly_order_preserving` that allow for more optimizations if the expression marked as keeping the same ordering this property means that given expression `f` and 2 values from the input column `a` and `b` the following variants are kept: 1. `a.cmp(b) == f(a).cmp(f(b))` 2. nulls maps to nulls Example of satisfying expression: `cast(col_a as BIGINT)` where `col_a` is `INT` it is keeping the properties Example of not satesfing: `floor` - floor can not `array_repeat(my_col, 2)` which might look like at first glance as keeping the property as well but in fact it does not. the reason is that `array_repeat(null, 2)` will output list of 2 nulls which breaks the 2nd property that nulls must be kept as nulls for more details on the property meaning and difference from `preserves_lex_ordering` see: https://github.com/apache/datafusion/blob/1c3232ce2262523fb4043e7264185b2f8f929b0d/datafusion/expr-common/src/sort_properties.rs#L151-L198 -- 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]
