Print table name in message about missing column.

This commit is contained in:
Ivan Lezhankin 2019-06-27 13:56:04 +03:00
parent bb77b7a326
commit 9d3eef80b0

View File

@ -157,7 +157,7 @@ void IStorage::check(const Names & column_names) const
{ {
if (columns_map.end() == columns_map.find(name)) if (columns_map.end() == columns_map.find(name))
throw Exception( throw Exception(
"There is no column with name " + name + " in table. There are columns: " + list_of_columns, "There is no column with name " + backQuote(name) + " in table " + getTableName() + ". There are columns: " + list_of_columns,
ErrorCodes::NO_SUCH_COLUMN_IN_TABLE); ErrorCodes::NO_SUCH_COLUMN_IN_TABLE);
if (unique_names.end() != unique_names.find(name)) if (unique_names.end() != unique_names.find(name))