dbms: Server: fix [#METR-19266]

This commit is contained in:
Alexey Arno 2016-10-18 22:31:07 +03:00
parent abe75277a3
commit e1099f47cb
2 changed files with 7 additions and 2 deletions

View File

@ -2345,7 +2345,12 @@ public:
void executeImpl(Block & block, const ColumnNumbers & arguments, const size_t result) override
{
wrapper_function(block, arguments, result);
/// drop second argument, pass others
ColumnNumbers new_arguments{arguments.front()};
if (arguments.size() > 2)
new_arguments.insert(std::end(new_arguments), std::next(std::begin(arguments), 2), std::end(arguments));
wrapper_function(block, new_arguments, result);
}
bool hasInformationAboutMonotonicity() const override

View File

@ -210,7 +210,7 @@ void AlterCommands::validate(IStorage * table, const Context & context)
{
if (std::end(columns) != column_it)
throw Exception{
"Cannot add column " + column_name + ": column with this name already exisits",
"Cannot add column " + column_name + ": column with this name already exists",
DB::ErrorCodes::ILLEGAL_COLUMN
};
}