v.25.6New Feature

Allow to choose DateTime parsing mode during

Add new setting cast_string_to_date_time_mode that allows to choose DateTime parsing mode during cast from String. #80210 (Pavel Kruglov). For example, you can set it to the best effort mode.
Introduces a new setting cast_string_to_date_time_mode that allows users to select the DateTime parsing mode when casting from String in ClickHouse.

Why it matters

This feature enables more flexible and reliable parsing of String values to DateTime types by allowing users to specify the parsing mode, such as a best effort mode, improving data ingestion and error handling when converting date/time strings.

How to use it

Users can enable or configure the behavior by setting the cast_string_to_date_time_mode setting. For example, to use the best effort parsing mode, set the value accordingly in the server or session settings before executing queries that cast strings to DateTime.