v.22.5Experimental Feature

Improvement to Cast Semistructured Data Columns to Nullable Type

Improvement for semistructured data: Allow to cast columns of type Object(...) to Object(Nullable(...)). #36564 (awakeljw).
Improved support for semistructured data by enabling casting from Object(...) types to Object(Nullable(...)) in ClickHouse.

Why it matters

This feature resolves the limitation where columns defined as Object(...) could not be directly cast to their nullable counterparts, Object(Nullable(...)). It enhances flexibility and ease of working with semistructured data by allowing safe casting that accounts for nullable fields, improving compatibility and data processing capabilities.

How to use it

Users can perform casts in their SQL queries to convert columns of type Object(...) to Object(Nullable(...)) directly using the CAST function. For example:

SELECT CAST(column_name AS Object(Nullable(...))) FROM table_name;