diff --git a/dbms/include/DB/Common/ExternalTable.h b/dbms/include/DB/Common/ExternalTable.h index b6a5f0f874a..8095b117df7 100644 --- a/dbms/include/DB/Common/ExternalTable.h +++ b/dbms/include/DB/Common/ExternalTable.h @@ -200,14 +200,14 @@ public: /// Получаем параметры name = content.get("name", "_data"); - format = params.get("format" + name, "TabSeparated"); + format = params.get(name + "_format", "TabSeparated"); - if (params.has("structure" + name)) - parseStructureFromStructureField(params.get("structure" + name)); - else if (params.has("types" + name)) - parseStructureFromTypesField(params.get("types" + name)); + if (params.has(name + "_structure")) + parseStructureFromStructureField(params.get(name + "_structure")); + else if (params.has(name + "_types")) + parseStructureFromTypesField(params.get(name + "_types")); else - throw Exception("Neither structure nor types have not been provided for external table " + name + ". Use fields structure" + name + " or types" + name + " to do so.", ErrorCodes::BAD_ARGUMENTS); + throw Exception("Neither structure nor types have not been provided for external table " + name + ". Use fields " + name + "_structure or " + name + "_types to do so.", ErrorCodes::BAD_ARGUMENTS); ExternalTableData data = getData(context); diff --git a/dbms/src/Server/HTTPHandler.cpp b/dbms/src/Server/HTTPHandler.cpp index c080f058559..1f3bb7a9443 100644 --- a/dbms/src/Server/HTTPHandler.cpp +++ b/dbms/src/Server/HTTPHandler.cpp @@ -99,9 +99,9 @@ void HTTPHandler::processQuery(Poco::Net::HTTPServerRequest & request, Poco::Net /// Удаляем уже нененужные параметры из хранилища, чтобы впоследствии не перепутать их с натройками контекста и параметрами запроса. for (const auto & it : handler.names) { - params.erase("format" + it); - params.erase("types" + it); - params.erase("structure" + it); + params.erase(it + "_format"); + params.erase(it + "_types"); + params.erase(it + "_structure"); } } else