> ## Documentation Index
> Fetch the complete documentation index at: /documents/llms.txt
> Use this file to discover all available pages before exploring further.

# hll_raw_agg

> Aggregate function that combines multiple HLL values into a single HLL for approximate COUNT(DISTINCT).

This function is an aggregate function that is used to aggregate HLL fields. It returns an HLL value.

## Syntax

```Haskell theme={null}
hll_raw_agg(hll)
```

## Parameters

`hll`: the HLL column that is generated by other columns or based on the loaded data.

## Return value

Returns a value of the HLL type.

## Examples

```Plain theme={null}
mysql> select k1, hll_cardinality(hll_raw_agg(v1)) from tbl group by k1;
+------+----------------------------------+
| k1   | hll_cardinality(hll_raw_agg(`v1`)) |
+------+----------------------------------+
|    2 |                                4 |
|    1 |                                3 |
+------+----------------------------------+
```


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.