v.21.1New Features

Support EXISTS DATABASE Syntax in ClickHouse

Support syntax EXISTS DATABASE name. #18458 (Du Chuan).
Support for EXISTS DATABASE name syntax in ClickHouse.

Why it matters

This feature introduces the ability to check the existence of a database using the concise EXISTS DATABASE name syntax. It helps users easily verify if a database exists without running complex queries, improving script readability and management of database-dependent logic.

How to use it

Use the new syntax by running a query like:

EXISTS DATABASE database_name

which returns 1 if the database exists, and 0 if it does not.