It hurts if server has millions of tables. See https://github.com/ClickHouse/ClickHouse/pull/3398 Please add some tests to ensure it won't be broken in future.