mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-11-23 16:12:01 +00:00
Implement method "structureEquals" for ColumnAggregateFunction
This commit is contained in:
parent
1c3b1fe353
commit
3e3cafc487
@ -157,6 +157,21 @@ void ColumnAggregateFunction::ensureOwnership()
|
||||
}
|
||||
|
||||
|
||||
bool ColumnAggregateFunction::structureEquals(const IColumn & to) const
|
||||
{
|
||||
const auto * to_concrete = typeid_cast<const ColumnAggregateFunction *>(&to);
|
||||
if (!to_concrete)
|
||||
return false;
|
||||
|
||||
/// AggregateFunctions must be the same.
|
||||
|
||||
const IAggregateFunction & func_this = *func;
|
||||
const IAggregateFunction & func_to = *to_concrete->func;
|
||||
|
||||
return typeid(func_this) == typeid(func_to);
|
||||
}
|
||||
|
||||
|
||||
void ColumnAggregateFunction::insertRangeFrom(const IColumn & from, size_t start, size_t length)
|
||||
{
|
||||
const ColumnAggregateFunction & from_concrete = assert_cast<const ColumnAggregateFunction &>(from);
|
||||
|
@ -204,6 +204,8 @@ public:
|
||||
}
|
||||
|
||||
void getExtremes(Field & min, Field & max) const override;
|
||||
|
||||
bool structureEquals(const IColumn &) const override;
|
||||
};
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user