# APPROX\_COUNT\_DISTINCT\_COMBINE

Merges two or more [HyperLogLog](http://en.wikipedia.org/wiki/HyperLogLog) states into a new state and returns a value of type `VARBINARY(16384)` representing the new state.

## Syntax

```sql
APPROX_COUNT_DISTINCT_COMBINE ( expr )

```

## Arguments

**expr**

An expression evaluating to a scalar value of type `VARBINARY(16384)`.

`expr` is typically the name of a column. In this case, `APPROX_COUNT_DISTINCT_COMBINE` uses values in the column (which are HyperLogLog states) to create a new state.

## Remarks

This function is used in conjunction with the `APPROX_COUNT_DISTINCT_ACCUMULATE` and `APPROX_COUNT_DISTINCT_ESTIMATE` [Distinct Count Estimation Functions](https://docs.singlestore.com/db/v9.1/reference/sql-reference/distinct-count-estimation-functions.md)

***

Modified at: February 24, 2023

Source: [/db/v9.1/reference/sql-reference/distinct-count-estimation-functions/approx-count-distinct-combine/](https://docs.singlestore.com/db/v9.1/reference/sql-reference/distinct-count-estimation-functions/approx-count-distinct-combine/)

(An index of the documentation is available at /llms.txt)
