[Yandex Cloud documentation](../../index.md) > [Yandex DataLens](../index.md) > Dashboards > Selectors

# Selectors in Yandex DataLens

Selectors are filters that affect the results of queries in the linked [widgets](widget.md).


{% note info %}

​To view the text of an SQL query from your chart to the data source, click ![image](../../_assets/console-icons/ellipsis.svg) in the top-right corner of the chart and select **Inspector**. You can find the query text in **Data sources** → **Query to data source**. For more information, see [Chart inspector in Yandex DataLens](../concepts/chart/inspector.md).

{% endnote %}


A selector can be linked to a chart or another selector. For more information, see [Link in Yandex DataLens](link.md).


Each selector may apply to a single dashboard tab, selected dashboard tabs, or the entire dashboard. A selector’s values are synchronized between tabs.


Selectors retain values when you switch between tabs: if you set a selector value, switch to another tab, and go back again, the selector's value will stay the same.

DataLens supports multiple selector types:

* **List**: Allows selecting one or multiple values from a list.
* **Input field**: Used for entering a field value manually.
* **Calendar**: Used for entering values of the `Date` or `Date and time` type.
* **Checkbox**: Allows selecting one of the two possible `Boolean` type values, `True` or `False`. To choose both boolean values, use the **List** selector type.

You can also [add a JS selector](../charts/editor/add-js-selector.md) to a dashboard.

In a single widget, you can [group](../operations/dashboard/add-selector.md) multiple selectors.

When working with a selector group:

* You can add **Apply** and **Reset** buttons to a widget with a selector group.


* For a widget with a selector group, you can configure which tabs to show it on.
* For each selector in a group, you can configure which tabs to show it on, or select to display it on tabs `From group settings`. The group settings restrict how you can set up individual selectors.


* To fix selectors inside the widget, specify the exact width for each one either in pixels or percent of widget width.
* To place selectors one under the other, specify `100%` width for each one of them.
* You can copy selectors and paste them into a group.

When adding a selector to a dashboard, consider how it affects chart filters:

* On a dashboard with no selector, the chart is displayed with an internal set of filters, if any.
* When adding a selector by a certain field to your dashboard, filters added at the chart level will no longer apply to the dashboard chart.
* If no value is selected in the selector (`No selected values`), the chart is displayed without filtering by this field even if there is a filter by this field at the chart level.

To apply double filtering to a field (through a selector and chart filter), create a duplicate of this field in the chart. In this case, you can apply filtering to the duplicate within the chart and add a selector by the original field to the dashboard.

Filters applied to charts using selectors are displayed in the **Dashboard filters** section. It is available if you open the chart to edit from the dashboard. To clear all the dashboard filters, click ![image](../../_assets/console-icons/trash-bin.svg) in the top-left corner of the section.

#### Useful links {#see-also}

* [Adding a selector to a dashboard in Yandex DataLens](../operations/dashboard/add-selector.md)
* [Adding a JS selector to a dashboard](../charts/editor/add-js-selector.md)