count_distinct

Description

Estimate the approximate number of distinct values in the input using hyper-log-log. (This is less precise, but faster than count_distinct_exact).

Return type

int64

Domain

This is an aggregate function (aggregates rows over a group in aggregate verbs.)

This is a window function (calculates over a group of multiple input rows using windowing.)

Categories

Usage

count_distinct( item ... )

Argument

Type

Required

Multiple

item

any

Required

Can be multiple

Aliases

countdistinct (deprecated)