# MV_FIRST

The MV_FIRST function converts a multivalued expression into a single valued column containing the first value.

## Syntax

`MV_FIRST(field)`

### Parameters

#### field

A multivalue expression.

## Examples

```esql
ROW a="foo;bar;baz"
| EVAL first_a = MV_FIRST(SPLIT(a, ";"))
```

```esql
ROW b="apple;banana;cherry"
| EVAL first_b = MV_FIRST(SPLIT(b, ";"))
```

## Notes

The MV_FIRST function is particularly useful when reading from a function that emits multivalued columns in a known order, such as SPLIT. However, it's important to note that the order in which multivalued fields are read from underlying storage is not guaranteed. While it's often ascending, this should not be relied upon. If you need the minimum value, use the MV_MIN function instead of MV_FIRST. MV_MIN has optimizations for sorted values, so there isn't a performance benefit to MV_FIRST.
