# Route

In this document, you will explore how to route datasets in Astera Dataprep. A Route transformation routes the data to multiple datasets based on custom decision logic expressed as rules or expressions. This allows the creation of multiple sub-datasets from the main dataset with records being directed to different datasets based on specified conditions.

1. Open a Recipe in Astera Dataprep.

![](/files/veBE4vG1oLgTczJXmejp)

2. Navigate to the Toolbar and select *Transform > Route*.

![](/files/Nr6FW0wuXdCplRZnKrbl)

3. Configure the following options in the recipe action in the Recipe Panel:

<img src="/files/7tIFfAOHCrkbuy1xbM8x" alt="" width="464">

* **Default Dataset Name**: This dataset contains all the records not passing any rules defined in the Route transformation expressions. It is required to set a name for the Default Dataset here.
* **Dataset Name**: The name of the dataset that will contain data for the records that pass/fulfill its specific expression's requirements.
* **Expression**: Enter an expression (e.g., Region = ‘North’) or any condition you want to apply to your data. Each Route expression you add here will create its own Dataset based on whether the records satisfy the expression.

4. In the Route Properties, click on the expression text entry box to enter an expression. You can enter the expression here or click the ![](/files/c7uvYM2mPruaOhq7IJyR) button to open the expression builder. Click ![](/files/V74elkQzaXkuEaz1P7zY) to approve and apply the expression.

<img src="/files/OtkDl0RXOVdwDTIu5uP4" alt="" width="405">

5. In this example, we have created three datasets based on the value in the *Region* field: one for *North\_Region*, one for *South\_Region*, and a default dataset named *Other\_Region*. Each dataset has an associated expression that routes records accordingly. \
   Records where the *Region* is *"North"* are sent to *North\_Region*, those with *"South"* go to *South\_Region*, and any records that do not match these conditions are routed to the default dataset, *Other\_Region*.

![](/files/RuIiEciWEO2rWmwUAJMn)

6. Click *Apply* ![](/files/PHTp9imqhWlBPUc5JPGr) to apply the changes or *Cancel* ![](/files/fTNZJlfigVTFubj5kxEO) to discard them.
7. Once you click *Apply*, the routed datasets are created and by default, the first Route Dataset (here: *“North”*) is previewed on the grid.

![](/files/Tv6FXX1WnZYK11i0Ojxy)

8. The other datasets can then be read using the [Read Dataset](/dataprep/reading-sources/reading-a-dataset.md) recipe action.

<img src="/files/8sevw7mWLIqhwVea4EbH" alt="" width="383">

![](/files/7qel6leR8W7APRT1q0J2)

This concludes the document on using Route in Astera Dataprep.


---

# 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://documentation.astera.com/dataprep/transforming-data/route.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.
