BITMAP_COUNT

functionsupportedCore SQL functions

docs.snowflake.com ↗

Aggregate functions

Given a bitmap that represents the set of distinct values for a column, returns the number of distinct value.

Syntax

BITMAP_COUNT( <bitmap> )

Parameters

NameRequiredDescription
bitmaprequiredThis expression must evaluate to a bitmap returned by the BITMAP_CONSTRUCT_AGG or BITMAP_OR_AGG functions.

Returns

The function returns the number of distinct values in a column, as represented by the bits set in the input bitmap.

See also