Zum Inhalt springen

Gibt mithilfe von HyperLogLog eine ungefähre Anzahl eindeutiger Werte zurück.

func.approx_count_distinct(get_column(table, 'user_id'))
func.approx_count_distinct(get_column(table, 'user_id'))
┌─────┐
│ 985 │
└─────┘
APPROX_COUNT_DISTINCT(<user_id>)
SELECT APPROX_COUNT_DISTINCT(user_id) FROM page_views;
┌─────┐
│ 985 │
└─────┘