'How do I configure DataStudio filter control to have a default selection of null?

I have a DataStudio chart of type table and a filter control both connected to the same datasource. The filter control references a dimension that can contain empty values. When applying a filter (by manual selection), the empty values appear as null and the table is filtered as expected.

My goal is to apply a default selection to the filter control so that empty values are included by default. The filter control allows me to provide a comma separated list for the default selection, however:

  • If I use the text null, it is treated as the text literal null. The same is true for (null) which is treated as the text literal (null).
  • If I use a leading comma (,filter), or a trailing comma (filter,), it is treated as filter and "" which doesn't match null.

The question is, how do I get a filter control's default selection to match results where the value is null/doesn't exist (by default)?



Solution 1:[1]

Edit (Apr 2022): As pointed out by @simplycoding below, this is now available by selecting a filter - Data - Control Field - Default selection.

Original Answer: This is currently not possible (Dec 2019). A workaround could be to create a calculated field where null values from the original column are replaced with a predefined value. Then filter based on the new column.

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1