## MV_COUNT

The `MV_COUNT` function in ES|QL is used to convert a multivalued expression into a single valued column containing a count of the number of values.

### Syntax

The syntax for using the `MV_COUNT` function is as follows:

`MV_COUNT(field)`

Here, `field` is a multivalue expression.

### Examples

Here are a couple of examples demonstrating the use of the `MV_COUNT` function:

```esql
ROW a=["foo", "zoo", "bar"]
| EVAL count_a = MV_COUNT(a)
```

In this example, the `MV_COUNT` function is used to count the number of values in the array `["foo", "zoo", "bar"]`, and the result is stored in the `count_a` column.

```esql
ROW b=[1, 2, 3, 4, 5]
| EVAL count_b = MV_COUNT(b)
```

In this second example, the `MV_COUNT` function is used to count the number of values in the array `[1, 2, 3, 4, 5]`, and the result is stored in the `count_b` column.
