v.21.11Improvements

Add external_table_strict_query setting to enforce full WHERE expression in foreign database queries

Add a setting external_table_strict_query - it will force passing the whole WHERE expression in queries to foreign databases even if it is incompatible. #29206 (Azat Khuzhin).
Introduces the external_table_strict_query setting to force passing the entire WHERE expression in queries to foreign databases, even if parts are incompatible.

Why it matters

This feature addresses the limitation where parts of the WHERE clause might be omitted when querying external databases due to incompatibility. By forcing the whole expression to be sent, it helps users ensure consistent filtering behavior on foreign tables and can improve query accuracy.

How to use it

Enable the feature by setting external_table_strict_query to 1 in your query settings or configuration. This will instruct ClickHouse to push down the complete WHERE clause to foreign databases regardless of compatibility concerns.