Dashboard filters
A dashboard filter is a control viewers can change at the top of the dashboard: “Location”, “Date range”, “Org unit” and so on. The filter is added to every chart whose dataset has its column; a chart without that column ignores the filter. Viewers cannot change the condition or the column; they only choose the values.
A chart’s own filter, by contrast, always applies and viewers cannot change it (Chart builder).
Adding a filter
Section titled “Adding a filter”First place at least one chart on the dashboard (“Place a chart on the dashboard before adding a filter.”).
- In the dashboard editor, go to the Dashboard filters section.
- Click Add dashboard filter. The new filter starts with the first column and the Is one of condition.
- Fill in the fields:
| Field | What to enter | Rule |
|---|---|---|
| Column | One of the columns of the datasets of the dashboard’s charts. The display name and the column name are listed together. | The column must be in at least one chart’s dataset. |
| Key | A short name for the filter, e.g. lokasyon. It is suggested when you choose the column. |
Letters, digits, _ or -; at most 40 characters; unique on the dashboard. |
| Label | The name viewers see, e.g. “Location”. Suggested from the column’s display name. | At most 100 characters. |
| Condition | Equals, Is one of, Between, Contains, Is empty, Is not empty. | — |
| Default value | The value applied when the dashboard opens. | Left empty, the filter does not apply until the viewer enters a value. |
- Save the dashboard.
A dashboard holds at most 20 filters. To remove a filter, use the remove button at the end of its row.
The control viewers see, by condition
Section titled “The control viewers see, by condition”| Condition | Viewer’s control | Default |
|---|---|---|
| Equals | A single-value choice (“Choose a value”). On a yes/no column: All / Yes / No. | Default value |
| Is one of | A multiple choice (“Choose values”, “3 selected”). | Default values |
| Between | From and to. On a date column, quick ranges: Last 7 days, Last 30 days, This month, This year. | Default range (two values or both empty) |
| Contains | A text box. | Default value |
| Is empty / Is not empty | Takes no value; “always applies”. | — |
Value lists come from the column’s real values (“Loading the values…”). If the list is long, the first values are shown with “Showing the first 100 values. Type to find the one you want.”; search with Search the values. You can type a value that is not in the list and choose it with “Use “…”“.
With the “Between” condition both ends of the range must be chosen; with one empty the filter does not apply (“Choose both ends of the range; with one empty the filter does not apply.”).
Why column names matter
Section titled “Why column names matter”A filter is linked to a column by its name. For a “Location” filter to apply to two charts, both charts’ datasets must have a
column with the same name (for example lokasyon). When you prepare different datasets, give shared columns the same name; in SQL
you can name them with AS lokasyon.
Messages
Section titled “Messages”- “Every filter needs a key: letters, digits, ‘_’ or ‘-’ (at most 40 characters).”
- “Filter keys must differ from each other.”
- “A filter label may be at most 100 characters.”
- “A filter’s column is not in the datasets of the dashboard’s charts.” — you took the last chart using the filter’s column off the dashboard.
- “A “between” filter’s default takes two values (or none).”
Example
Section titled “Example”For an inspection dashboard:
| Key | Label | Column | Condition | Default |
|---|---|---|---|---|
tarih |
Date | submitted_at |
Between | empty (the viewer picks a quick range) |
lokasyon |
Location | lokasyon |
Is one of | empty |
gecti |
Passed | passed |
Equals | empty (All) |
When a viewer chooses This month for Date and “İzmir Fabrikası” for Location and clicks Apply, every chart on the dashboard is filtered to this month and this location (My dashboards).