mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-11-23 08:02:02 +00:00
support nullable arguments in function initializeAggregation
This commit is contained in:
parent
5802037f1e
commit
4d020c96e0
@ -40,6 +40,7 @@ public:
|
||||
bool isSuitableForShortCircuitArgumentsExecution(const DataTypesWithConstInfo & /*arguments*/) const override { return true; }
|
||||
|
||||
bool useDefaultImplementationForConstants() const override { return true; }
|
||||
bool useDefaultImplementationForNulls() const override { return false; }
|
||||
ColumnNumbers getArgumentsThatAreAlwaysConstant() const override { return {0}; }
|
||||
|
||||
DataTypePtr getReturnTypeImpl(const ColumnsWithTypeAndName & arguments) const override;
|
||||
|
@ -0,0 +1,6 @@
|
||||
1
|
||||
AggregateFunction(uniqExact, Nullable(String))
|
||||
1
|
||||
AggregateFunction(uniqExact, Nullable(UInt8))
|
||||
1
|
||||
1
|
@ -0,0 +1,8 @@
|
||||
SELECT finalizeAggregation(initializeAggregation('uniqExactState', toNullable('foo')));
|
||||
SELECT toTypeName(initializeAggregation('uniqExactState', toNullable('foo')));
|
||||
|
||||
SELECT finalizeAggregation(initializeAggregation('uniqExactState', toNullable(123)));
|
||||
SELECT toTypeName(initializeAggregation('uniqExactState', toNullable(123)));
|
||||
|
||||
SELECT initializeAggregation('uniqExactState', toNullable('foo')) = arrayReduce('uniqExactState', [toNullable('foo')]);
|
||||
SELECT initializeAggregation('uniqExactState', toNullable(123)) = arrayReduce('uniqExactState', [toNullable(123)]);
|
Loading…
Reference in New Issue
Block a user