When using dictGet with equivalence filtering, the optimization works, but it does not work when filtering is used by a list (IN). This feature would ensure that the optimization is consistent across different filtering methods.
### Company or project name _No response_ ### Describe what's wrong When using dictGet in the request body with equivalence filtering, the optimization works. If filtering is used by a list (IN), then optimization does not work. ### Does it reproduce on the most recent release? Yes ### How to reproduce 26.1.4 click house-client `CREATE TABLE t1 (id Int32, val Int32) ENGINE = MergeTree() PARTITION BY id%100 ORDER BY id; CREATE TABLE t2 (id Int32, name String) ENGINE = MergeTree() ORDER BY id; INSERT INTO t1 SELECT number%100, number*100 FROM numbers(10000); INSERT INTO t2 SELECT number, 'S-'||toString(number) FROM numbers(100); CREATE DICTIONARY d (id Int32, name String) PRIMARY KEY id SOURCE(CLICKHOUSE(QUERY `SELECT id, name FROM t2`)) LAYOUT(HASHED) LIFETIME(MIN 300 MAX 3000); EXPLAIN indexes=1 SELECT t1.id, t1.val, dictGet('d','name',t1.id) as name FROM t1 WHERE name IN ('S-9') SETTINGS optimize_inverse_dictionary_lookup = 1 ;` https://fiddle.clickhouse.com/3b09a60