> For the complete documentation index, see [llms.txt](https://docs.gridmate.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.gridmate.io/product-tour/grids/user-grid/filters-and-search.md). Agents can also search and read this documentation through its [MCP server](https://docs.gridmate.io/~gitbook/mcp).

# Filters & Search

Filter User Grid records with the Quick Filter or the Advanced Filter, and limit what users can see.

GridMate provides two methods for filtering the data: The **Advanced Filter** allows you to create more complex and intricate filters, while the **Quick Filter** provides an easy way to explore the grid without delving deeper into the conditions.

Grid owners can also limit the records of a grid with an **Admin Filter**, and switch the user filters off.

## Which setting do I need?

| I want to…                                        | Use                                                                                                                                                            |
| ------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| Filter quickly by one or several fields           | [Quick Filter](#quick-filter)                                                                                                                                  |
| Combine conditions with AND, OR and child records | [Advanced Filter](#advanced-filter)                                                                                                                            |
| Limit the records every user of the grid can see  | [Admin Filter](#admin-filter)                                                                                                                                  |
| Stop users from saving their own filters          | [Disable End User Filter](#disable-end-user-filter)                                                                                                            |
| Add a search box to the grid                      | The **Search** section of the Config Wiz, on the [Set up](https://docs.gridmate.io/product-tour/grids/user-grid/set-up.md#configure-it-in-the-config-wiz) page |

## Quick Filter

GridMate provides flexible **Quick Filter** tools similar to the one provided by Salesforce standard UI. The filter is dynamic based on the field type:

* **Lookup Picker** for lookup fields.
* **Range** for dates, date times, currencies, percentages and other number fields.
* **Multiple Choice** for PickList and Multi-Picklist fields.
* **Radio Button** for checkbox fields.
* **Multiple Entries** for text fields.

To use it:

1. Click the **Grid Explorer** and select the **Filter** section.
2. Choose a field and set its value.
3. Click **Apply**.

The video below filters an Opportunity grid by account, amount range, stage and name.

{% embed url="<https://youtu.be/QzGIdu5YmKE>" %}
Quick Filter
{% endembed %}

{% hint style="info" %}
The Quick Filter supports **only** the following field types: Boolean, Currency, Double, Integer, Percent, Date, Datetime, Picklist, Multi-Picklist, String, and Reference.
{% endhint %}

## Advanced Filter

GridMate offers flexible and powerful **Query Builder.** Using this tool, the end user will be able to build advanced filters including:

* **Simple Condition** : a basic condition to apply on a single field using an operator (<, >, =,...) and optionally a value to compare with.
* **Complex Condition**: an OR/AND junction that involves multiple single or complex conditions. With this formalism, we can express any logical condition.
* **Cross Filters**: a condition to check the existence or not of a child record. A Cross Filter could also be expressed using simple condition to filter the child records.

To use it:

1. Click the **Grid Explorer** and select the **Filter** section.
2. Click **Add Condition** to add a simple condition.
3. Click **Add Group** and select **OR** or **AND** to add a complex condition.
4. Click **Add Cross Filter** to check for child records.
5. Click **Apply**.

The video below turns the quick filter of the previous demo into an advanced filter with an OR group and a cross filter.

{% embed url="<https://youtu.be/QPxJEILeuP0>" %}
Advanced Filter
{% endembed %}

{% hint style="info" %}
The quick filters are automatically converted into an advanced filter. Remember that you can upgrade the quick filter to an advanced filter, but the inverse process is not allowed.
{% endhint %}

Behind the scenes, the Query Builder produces a **JSON** like filter used by GridMate components. Below is the produced configuration for the tutorial above.

```json
{
    "and": [
        {
            "StageName": {
                "operator": "in",
                "value": "('Prospecting','Qualification','Needs Analysis','Proposal/Price Quote')"
            }
        },
        {
            "or": [
                {
                    "Amount": {
                        "operator": ">=",
                        "value": "5000"
                    }
                },
                {
                    "CloseDate": {
                        "operator": "=",
                        "value": "THIS_YEAR"
                    }
                }
            ]
        },
        {
            "with OpportunityContactRoles": {
                "operator": "with",
                "field": "OpportunityId",
                "childSObject": "OpportunityContactRole",
                "value": {}
            }
        }
    ]
}
```

## Admin Filter

GridMate provides an **Admin Filter** that can be created to limit the scope for a given **User Grid**. When an admin filter is defined, the user will never be able to go beyond that scope.

1. Open the **Config Wiz**.
2. Select the **Admin Filter** section.
3. Define the criteria by choosing the field and the value.
4. Add a label if desired.
5. Click **Save**.

Users can still filter the grid by any other field from the **Grid Explorer**.

The video below creates an admin filter on an Account grid, then checks it as a standard user.

{% embed url="<https://youtu.be/EEacp3vqGRU>" %}
Admin Filter
{% endembed %}

## Disable End User Filter

**Disable End User Filter** turns off the **Filter Builder**, which allows users to create complex filters using logical operators like AND/OR.

1. Click the gear icon to open the **Config Wiz**.
2. Click **Advanced**.
3. In the **Miscellaneous** section, scroll down to **User Filter**.
4. Disable it and click **Save**.

Once disabled, the saved filters and the related quick filter links are removed from the grid.

The video below disables the user filter on a User Grid.

{% embed url="<https://youtu.be/w4BG3l1pvMA>" %}

## Next steps

<table data-view="cards"><thead><tr><th></th><th></th><th data-hidden data-card-target data-type="content-ref"></th></tr></thead><tbody><tr><td><strong>Create &#x26; Edit Records</strong></td><td>Set up the form for new records and choose who can create, edit and delete.</td><td><a href="https://docs.gridmate.io/product-tour/grids/user-grid/create-and-edit-records.md">Create &amp; Edit Records</a></td></tr><tr><td><strong>Grid - Advanced Filtering</strong></td><td>Filter grid records with junctions, inline SOQL, merge fields and Apex value providers.</td><td><a href="https://docs.gridmate.io/advanced-guides/smart-grid/filtering/grid-advanced-filtering.md">Grid - Advanced Filtering</a></td></tr><tr><td><strong>Grid - Interactive Filters</strong></td><td>Filter grid columns by value, condition or color, like in a spreadsheet.</td><td><a href="https://docs.gridmate.io/advanced-guides/smart-grid/filtering/grid-interactive-filters.md">Grid - Interactive Filters</a></td></tr><tr><td><strong>GM - User Grid</strong></td><td>Every property of the component.</td><td><a href="https://docs.gridmate.io/package-reference/components-library/grids/gm-user-grid.md">GM - User Grid</a></td></tr></tbody></table>


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

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

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.gridmate.io/product-tour/grids/user-grid/filters-and-search.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

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.
