# Filter

In this document, you’ll learn how to use the *Filter* transformation in Astera Dataprep to include or exclude records based on a specified condition within your Dataprep Recipe.

Suppose you have a dataset of transactions, but some rows have missing transaction amounts. These incomplete records could lead to incorrect revenue calculations. By applying a filter, you can remove rows where the transaction amount is missing, ensuring that only valid transactions are included in the analysis.

![](/files/Z2surJH3wteIMyPdk4nu)

1. To filter in Astera Dataprep, click on the *Transform* option in the toolbar and select *Filter* from the drop-down.

![](/files/phIwBCNXDUbikwdyCZFg)

2. Once selected, the *Recipe Configuration – Filter* panel will open.

<img src="/files/3Nx8dHBDYmQJ6hehCKUW" alt="" width="380">

**Filter Condition:** Here, you can configure the Filter section by entering a condition to include or exclude records.

3. Click on the <img src="/files/omwF77efcfE3pOW8XY5U" alt="" data-size="line"> three dots to open *Expression Builder*. Here you can either write your own expression or choose from the built-in functions' library.\
   For example, to remove rows where the *Amount* field is missing, you can enter: *Amount IS NOT null*
4. Once done, click <img src="/files/IjeFWKJhJF5PrP8XqOxy" alt="" data-size="line"> Apply.
5. Now, in the grid, you can see that only records meeting the specified condition remain in the dataset.

![](/files/GfXHJdxkQIUdaqJRGQQL)

{% hint style="info" %}
**Tip:** You can also ask in Chat to remove rows with missing amounts, and Dataprep will configure the filter for you automatically.
{% endhint %}

![](/files/hQXPhqVrWSRvXUoIUxQq)


---

# 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/filter.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.
