# Split Data

The **Split Data** building block allows you to break a value into multiple parts and save them into separate columns or variables.

#### How It Works

* **Value to split** – Select the value that should be split (e.g., a full name or an address).
* **Separator** – Define the character or text that separates the parts (e.g., a space, comma, or custom delimiter).
* **Positions to save** – Specify which parts to extract and where to store them.

#### Example: Split full name to first and last name

Consider this to be your initial table:

<figure><img src="/files/JTGixKYWDO5LM8EsifdW" alt=""><figcaption></figcaption></figure>

How to set up the Split Data building block:

<figure><img src="/files/SrsCcGNR2jxZNDh2bRKW" alt=""><figcaption></figcaption></figure>

This is the end result after running your TaskBot:

<figure><img src="/files/LD2tMJdjbyRcxUlkqYSU" alt=""><figcaption></figcaption></figure>

#### Split from the End of Text

You can enter **negative numbers** in position fields to split from the end of text.

#### **Behavior During Run**

* If the split value **does not contain a requested position**, nothing is saved for that position, and no action is taken.
* **Positive positions** (e.g., `1`, `2`, `3`) start counting from the beginning.&#x20;

  **Examples**:

  * "Hello world", position 1 ⟶ "Hello"
  * "Hello world", position 2 ⟶ "world"
  * "Hello world", position 3 ⟶ *(nothing gets saved)*
* **Negative positions** (e.g., `-1`, `-2`, `-3`) allow counting from the end. *(Supported from the agent version 1.1.61.)*

  **Examples**:

  * "Hello world", position -1 ⟶ "world"
  * "Hello world", position -2 ⟶ "Hello"
  * "Hello world", position -3 ⟶ *(nothing gets saved)*
* **Position 0 is not valid** and does not correspond to any value. TaskBot will generate an error if 0 is used.

### Video Tutorial

{% embed url="<https://youtu.be/iQkygDVEm9Y?si=aZVE5SceNYu0YTJy>" %}


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.zerowork.io/using-zerowork/using-building-blocks/split-data.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
