v.21.8Improvement

Support for Materialized and Aliased Columns in JOIN

Support materialized and aliased columns in JOIN, close #13274. #25634 (Vladimir C).
ClickHouse now supports using materialized and aliased columns in JOIN queries, enabling more flexible and powerful join operations.

Why it matters

Previously, materialized and aliased columns could not be referenced in JOIN conditions or clauses, limiting query expressiveness. This feature addresses that limitation, allowing users to leverage computed or shorthand columns directly in join operations, enhancing query capability and simplifying complex data retrieval tasks.

How to use it

Users can directly reference materialized or aliased columns in JOIN clauses just like regular columns without requiring workarounds. No special configuration is needed; simply write joins that include these columns in the ON or USING parts of the JOIN statement.