v.23.8Improvement

Simplifying Case Sensitivity in ClickHouse's Information Schema

Closes #49510. Currently we have database and table names case-sensitive, but BI tools query information_schema sometimes in lowercase, sometimes in uppercase. For this reason we have information_schema database, containing lowercase tables, such as information_schema.tables and INFORMATION_SCHEMA database, containing uppercase tables, such as INFORMATION_SCHEMA.TABLES. But some tools are querying INFORMATION_SCHEMA.tables and information_schema.TABLES. The proposed solution is to duplicate both lowercase and uppercase tables in lowercase and uppercase information_schema database. #52695 (Yarik Briukhovetskyi).
ClickHouse now supports both lowercase and uppercase versions of information_schema and its tables, enabling case-insensitive access to metadata by duplicating tables in both casing styles.

Why it matters

This feature addresses compatibility issues with BI tools that query information_schema using inconsistent case for database and table names. Previously, separate lowercase and uppercase databases existed, but some tools use mixed-case queries like INFORMATION_SCHEMA.tables. By duplicating tables in both lowercase and uppercase within the information_schema database, ClickHouse ensures all case variants are recognized, improving usability and integration with external tools.

How to use it

Users do not need to perform any special action; ClickHouse automatically provides both lowercase and uppercase versions of the information_schema tables within the information_schema database. Queries can use any case combination for information_schema and its tables, for example:

SELECT  FROM information_schema.tables;
SELECT
FROM INFORMATION_SCHEMA.TABLES;
SELECT * FROM INFORMATION_SCHEMA.tables;

All will return the appropriate metadata transparently.