Enlarge constant default column if it's empty

This commit is contained in:
alesapin 2018-10-25 17:54:00 +03:00
parent 54a1f0c2a6
commit c3159af898

View File

@ -288,7 +288,10 @@ bool PreparedFunctionImpl::defaultImplementationForConstantArguments(Block & blo
const ColumnWithTypeAndName & column = block.getByPosition(args[arg_num]);
if (arguments_to_remain_constants.end() != std::find(arguments_to_remain_constants.begin(), arguments_to_remain_constants.end(), arg_num))
temporary_block.insert(column);
if (column.column->empty())
temporary_block.insert({column.column->cloneResized(1), column.type, column.name});
else
temporary_block.insert(column);
else
{
have_converted_columns = true;