Fixed tests

This commit is contained in:
Maksim Kita 2023-06-04 15:02:46 +03:00
parent e28dfb7ea8
commit 46cbdeeb7e
3 changed files with 2 additions and 4 deletions

View File

@ -1120,9 +1120,8 @@ public:
ColumnPtr getConstantResultForNonConstArguments(const ColumnsWithTypeAndName & arguments, const DataTypePtr & result_type) const override ColumnPtr getConstantResultForNonConstArguments(const ColumnsWithTypeAndName & arguments, const DataTypePtr & result_type) const override
{ {
const ColumnWithTypeAndName & arg_cond = arguments[0]; const ColumnWithTypeAndName & arg_cond = arguments[0];
if (!arg_cond.column || !isColumnConst(*arg_cond.column)) { if (!arg_cond.column || !isColumnConst(*arg_cond.column))
return {}; return {};
}
const ColumnConst * cond_const_col = checkAndGetColumnConst<ColumnVector<UInt8>>(arg_cond.column.get()); const ColumnConst * cond_const_col = checkAndGetColumnConst<ColumnVector<UInt8>>(arg_cond.column.get());
bool condition_value = cond_const_col->getValue<UInt8>(); bool condition_value = cond_const_col->getValue<UInt8>();
@ -1135,9 +1134,8 @@ public:
return {}; return {};
auto result = castColumn(potential_const_column, result_type); auto result = castColumn(potential_const_column, result_type);
if (!isColumnConst(*result)) { if (!isColumnConst(*result))
return {}; return {};
}
return result; return result;
} }