Complete dictionary names in clickhouse-client

Since system.tables does not includes all dictionaries (dictionaries
declared via configuration files -- *.xml), and since this are those
dictionaries we should use regular system.dictionaries.name over
system.dictionaries.origin.
This commit is contained in:
Azat Khuzhin 2020-06-05 01:56:11 +03:00
parent 5d3383edbe
commit 16a22daf00

View File

@ -114,6 +114,8 @@ void Suggest::loadImpl(Connection & connection, const ConnectionTimeouts & timeo
<< " UNION ALL "
"SELECT DISTINCT name FROM system.tables LIMIT " << limit_str
<< " UNION ALL "
"SELECT DISTINCT name FROM system.dictionaries LIMIT " << limit_str
<< " UNION ALL "
"SELECT DISTINCT name FROM system.columns LIMIT " << limit_str;
}