diff --git a/src/Parsers/ASTSelectQuery.cpp b/src/Parsers/ASTSelectQuery.cpp index b97c3dbc585..b187dc74f02 100644 --- a/src/Parsers/ASTSelectQuery.cpp +++ b/src/Parsers/ASTSelectQuery.cpp @@ -8,7 +8,10 @@ #include #include #include +#include +#include +#include namespace DB { @@ -513,7 +516,7 @@ NameToNameMap ASTSelectQuery::getQueryParameterValues() const if (auto literal = expression_list->children[1]->as()) { - parameter_values[identifier->name()] = toString(literal->value); + parameter_values[identifier->name()] = convertFieldToString(literal->value); } } } diff --git a/src/Parsers/ASTSelectQuery.h b/src/Parsers/ASTSelectQuery.h index e8eed092472..8ece05808f7 100644 --- a/src/Parsers/ASTSelectQuery.h +++ b/src/Parsers/ASTSelectQuery.h @@ -2,9 +2,6 @@ #include #include -#include -#include -#include namespace DB { diff --git a/src/Parsers/ASTSelectWithUnionQuery.cpp b/src/Parsers/ASTSelectWithUnionQuery.cpp index 11ac252aee2..c38e4e2c747 100644 --- a/src/Parsers/ASTSelectWithUnionQuery.cpp +++ b/src/Parsers/ASTSelectWithUnionQuery.cpp @@ -3,7 +3,9 @@ #include #include #include +#include +#include #include namespace DB diff --git a/src/Parsers/ASTSelectWithUnionQuery.h b/src/Parsers/ASTSelectWithUnionQuery.h index ef8e50c47fd..8d93760426a 100644 --- a/src/Parsers/ASTSelectWithUnionQuery.h +++ b/src/Parsers/ASTSelectWithUnionQuery.h @@ -2,8 +2,6 @@ #include #include -#include -#include namespace DB {