> For the complete documentation index, see [llms.txt](https://docs.scaleflex.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.scaleflex.com/portals/portal-settings/datasets/connect-to-dataset/criteria.md). Agents can also search and read this documentation through its [MCP server](https://docs.scaleflex.com/~gitbook/mcp).

# Criteria

Which rows the list shows, and what visitors are allowed to narrow it by.

**Criteria** answers *which rows, and what may a visitor change?* It appears only once a dataset is chosen on the [Context](https://docs.scaleflex.com/portals/portal-settings/datasets/connect-to-dataset/context.md) tab, and both halves are optional — an untouched Criteria tab means the list shows everything, with no filters.

The two halves pull in opposite directions, which is the thing to understand:

| Half                | Set by | Visitor can change it  | Narrows                           |
| ------------------- | ------ | ---------------------- | --------------------------------- |
| **Fixed criteria**  | You    | No — they never see it | What the list contains at all     |
| **Visitor filters** | You    | Yes                    | What they're looking at right now |

## Fixed criteria

Narrows the list before anyone sees it. **Add a criterion** builds a rule reading **Show items where** *field* *operator* *value*, and **And where** for each one after — they're combined with AND, so every rule has to hold.

This is what lets one dataset feed a different list on every page. A single changelog can appear as *Portals only* on one page, *This year's security fixes* on another, and in full on a third, with the entries written once.

<figure><img src="https://2536208400-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fqsq2dR7Fjagf5eTifWZx%2Fuploads%2FEe4DnhEkuWrc7zBNyG9I%2FScreenshot%202026-11-11%20150016.png?alt=media&amp;token=27d587b9-3da9-4c90-aa49-0ea14b729d3c" alt=""><figcaption><p>A fixed criterion — <strong>Show items where</strong> a field, an operator and a value.</p></figcaption></figure>

Which operators you get depends on the field:

| Field type                                                    | Operators                                                                                      |
| ------------------------------------------------------------- | ---------------------------------------------------------------------------------------------- |
| **Single** or **Multiple choice**                             | Is · Is not · Is one of · Is not one of · Is set · Is not set                                  |
| **Text**, **Rich text**, **Media**, **Link**, **Portal page** | Is · Is not · Contains · Is set · Is not set                                                   |
| **Number**                                                    | Is · Is not · Is set · Is not set                                                              |
| **Date**                                                      | Contains · Is set · Is not set — the value is a year or a year-month, like `2026` or `2026-08` |
| **Yes / no**                                                  | Is · Is set · Is not set                                                                       |

**Is set** and **Is not set** need no value; they ask only whether the field was filled in. Every other operator filters on what you give it.

With nothing added the panel reads **No fixed criteria yet**.

### On a dataset page

When the list sits on a [dataset page](https://docs.scaleflex.com/portals/portal-settings/datasets/dataset-pages.md) of the same dataset it reads, a criterion can follow the entry being shown. That is how a product page lists *other products from the same collection* without a separate list per product:

* The field picker gains **Item** — the row itself. It takes **Is not** or **Is**, with the value **This item**. **Item** **Is not** **This item** keeps the entry a visitor is reading out of its own list.
* A **Single choice**, **Multiple choice** or **Yes / no** field offers **Same as this item** at the top of its values. *Collection* **Is** **Same as this item** lists only the rows that share the entry's collection.

Each entry's page fills these in with its own values, and the builder previews them against the entry the canvas shows. Neither is offered on an ordinary page, or on a list connected to a different dataset.

## Visitor filters

Controls visitors use to narrow the list themselves. **Add a filter** picks the **Field**, the **Control** it's drawn as, and the wording of its clear-everything option.

| Control             | Looks like                       | Suits                                  |
| ------------------- | -------------------------------- | -------------------------------------- |
| **Pill row**        | A row of pills, one per value    | A handful of values, all worth showing |
| **Dropdown**        | A single dropdown                | More values than fit a row             |
| **Searchable list** | A list with a search box over it | Long option lists                      |

<figure><img src="https://2536208400-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fqsq2dR7Fjagf5eTifWZx%2Fuploads%2Fq9Wl7bPObF9vHgM9uXAM%2Fimage.png?alt=media&#x26;token=2a2a4b8c-091a-4db1-a435-d8b454f8ad45" alt=""><figcaption><p>A visitor filter: the field it reads, and the control it is drawn as.</p></figcaption></figure>

**"All" label** is the wording of the option that clears the filter; it reads **All** unless you change it.

Only **Single choice** and **Multiple choice** fields qualify. A filter over free text would be a search box with no vocabulary, and one over a date would list every distinct timestamp — so if the dataset has no choice field, the tab tells you to add one.

Filtering runs on the server against the whole dataset, not over the rows already on screen. A visitor filtering a 96-row page of a 4,000-row dataset gets all the matches, not the matches among those 96.

{% hint style="warning" %}
**Don't filter on a field a criterion already fixes.** If a fixed criterion pins a field to one value with **Is** or **Is one of**, and you also offer that field as a visitor filter, every value the visitor picks will empty the list — the two rules contradict each other. The dialog flags it in red: *A criterion already fixes this field, so every value a visitor picks here will empty the list. Remove one of the two.*
{% endhint %}

## Visitor search

Where a filter needs a vocabulary, a search box takes whatever the visitor types. Turn on **Visitor search** to put *a search box above the list. It matches any of the fields ticked below, across the whole dataset — not just the items on screen.*

* **Search in (none ticked: every text field)** — tick the fields it should look in. **Text**, **Rich text**, **Single choice** and **Multiple choice** fields can be ticked; leave them all unticked to search every text field.
* **Placeholder** — the hint shown in the empty box, for example *Search a destination…*.

Search and visitor filters work together: a visitor can pick a filter and search within what it leaves. A field ticked here is listed as **Visitor search** when you go to delete it, like any other place that reads it.

### Order

The filter bar draws your filters in two rows: every **Dropdown** and **Searchable list** sits beside the search box, and each **Pill row** takes a line of its own below them. The dialog lists them the same way — compact controls first, then pill rows — so the order you see here is the order visitors get.

To change it, drag a filter by its handle. A filter moves only within its own group: a pill row can't go above a dropdown, because the bar would never draw it there. The handle appears once a group has two or more filters.

Changing a filter's **Control** between **Pill row** and either of the others moves it to the end of the other group, and the dialog highlights it so you can see where it went.

{% hint style="info" %}
From the keyboard: focus the handle, press **Space** to pick the filter up, move it with the arrow keys, and press **Space** again to drop it. **Escape** puts it back.
{% endhint %}

## Which to reach for

Ask who the narrowing is for. If every visitor to this page should see the same subset — one product's notes, one year, one department — that's a **fixed criterion**, and it belongs here invisibly. If different visitors want different cuts of the same set, that's a **visitor filter**, and you're offering a control rather than making a decision.

A page can use both: fix the product, and let visitors filter by status within it.
