Multi-select dropdown parameter doesn't allow CONTAINS filter

The error message you’re encountering indicates that the multi-select dropdown controls you’ve enabled are not compatible with the “CONTAINS” filter applied on the column KPI_SUB in your visuals. It seems that the filter is causing conflicts with the multi-select functionality.

To resolve this issue, you can consider an alternative approach for filtering based on the KPI_SUB column. Instead of using a “CONTAINS” filter, you can try using a different filter type that is compatible with multi-select dropdown controls.

One possible alternative is to use a “IN” filter. Instead of filtering based on partial string matches, you would filter based on exact matches. Here’s an example of how you can modify your calculated field and filter expression:

  1. Modify your calculated field, KPI_SUB, to generate a list of values or categories. Instead of using the “contains” function, you can use a combination of logical conditions (e.g., “IF” or “CASE” statements) to assign values to specific categories.

    For example, instead of:

    KPI_SUB = IFELSE(CONTAINS([column], "substring"), "Category 1", "Category 2")
    

    You can use:

    KPI_SUB = IF([column] LIKE "substring%", "Category 1",
                IF([column] LIKE "another substring%", "Category 2", "Category 3"))
    

    Adjust the conditions and categories according to your specific requirements.

  2. Apply an “IN” filter on the KPI_SUB column in your visual. In the filter settings, you can select the “Include” option and choose the desired categories or values from the multi-select dropdown controls.

    For example, instead of:

    Filter: CONTAINS(KPI_SUB, "Category 1")
    

    You can use:

    Filter: KPI_SUB IN ("Category 1", "Category 2")
    

    Adjust the categories or values based on the options available in your KPI_SUB calculated field.

By using the “IN” filter with exact matches and modifying your calculated field to generate specific categories, you can maintain compatibility between the multi-select dropdown controls and the filter applied on the KPI_SUB column. This should help resolve the error and allow you to filter your visuals based on the selected categories or values.

1 Like