﻿---
title: ES|QL SPLIT function
description: 
url: https://www.elastic.co/elastic/docs-builder/docs/2869/reference/query-languages/esql/functions-operators/string-functions/split
products:
  - Elasticsearch
---

# ES|QL SPLIT function
## Syntax

![Embedded](https://www.elastic.co/elastic/docs-builder/docs/2869/reference/query-languages/esql/images/functions/split.svg)


## Parameters

<definitions>
  <definition term="string">
    String expression. If `null`, the function returns `null`.
  </definition>
  <definition term="delim">
    Delimiter. Only single byte delimiters are currently supported.
  </definition>
</definitions>


## Description

Split a single valued string into multiple strings.

## Supported types


| string  | delim   | result  |
|---------|---------|---------|
| keyword | keyword | keyword |
| keyword | text    | keyword |
| text    | keyword | keyword |
| text    | text    | keyword |


## Example

```esql
ROW words="foo;bar;baz;qux;quux;corge"
| EVAL word = SPLIT(words, ";")
```


| words:keyword              | word:keyword                 |
|----------------------------|------------------------------|
| foo;bar;baz;qux;quux;corge | [foo,bar,baz,qux,quux,corge] |