[SIP-25] Proposal for text based dashboard filters
See original GitHub issue[SIP-25] Proposal for text based dashboard filters
Motivation
In our projects analysts need to browse through large dataset (7M rows). They often need to search for rows by values which are unique or have very large number of unique values. Current implementation of dashboard filters is based on limited number of value buckets and does not allow them to do this.
Proposed Change
Add new visualization type - ‘Search Box’ which would allow to specify filter values by free typing.
New chart type should at least enable filtering with ‘==’ operator. Additionally every defined filter could allow for different filtering operators to be used:
For text columns:
- contains =>
column LIKE '%value%'
- does not contain =>
column NOT LIKE '%value%'
- starts with =>
column LIKE '%value'
- ends with =>
column LIKE 'value%'
- is empty =>
column IS NULL
- is not empty =>
column IS NOT NULL
For number columns: arithmetical comparison operators.
Similar functionality is already present in chart query configuration section. We would like to see similar functionality on dashboard level available to the end users of the dashboards.
New visualization would not need to perform any queries to render. It would be based on table metadata only.
New or Changed Public Interfaces
Base version of this improvement containing only ability to filter by exact value(==
) requires only new visualization to be prepared. It would emit filters in the same way that ‘Filter Box’ and ‘Table’ charts do.
Extended version requires changes in how filter state is stored on Dashboard level - it should contain information about used comparison operator. Also new addFilter action should be added and getEffectiveExtraFilters
function should be extended.
New dependencies
None
Migration Plan and Compatibility
n/a
Rejected Alternatives
Existing ‘Filter Box’ visualization could be extended to allow for free input, but it is probably better to separate slice which performs query from one which can be rendered without fetching any data.
Issue Analytics
- State:
- Created 4 years ago
- Reactions:23
- Comments:14 (6 by maintainers)
Top GitHub Comments
Is there an existing solution for performing LIKE queries for searching inside of a text column? Got to this issue from google trying to find a solution.
Reopening since Native Filters doesn’t quite cover what this SIP asks for. Technically this is discussion, so we’ll leave it there.