v.24.10Improvement

Always Use New Analyzer for Constant Expression Calculation

Always use the new analyzer to calculate constant expressions when enable_analyzer is set to true. Support calculation of executable table function arguments without using SELECT query for constant expressions. #69292 (Dmitry Novik).
Enhance constant expression calculation by always using the new analyzer when enable_analyzer is set to true, including support for evaluating executable table function arguments without requiring a SELECT query.

Why it matters

This feature improves the efficiency and consistency of constant expression evaluation in ClickHouse by leveraging the new analyzer. It eliminates the need to wrap executable table function arguments in a SELECT query to calculate constants, simplifying query writing and potentially improving performance.

How to use it

Enable the new analyzer by setting the enable_analyzer parameter to true. Once enabled, constant expressions, including those in executable table function arguments, will be calculated automatically without the need for a SELECT wrapper.