KNOWLEDGE BASE

Null Values are Excluded When Using The "Contains" Search Option And Choosing "Keep Only"


Published: 05 Jan 2024
Last Modified Date: 05 Jan 2024

Environment

  • Tableau Prep Builder

Resolution


Select "Does not contain" and "Keep Only" instead can generate the following calculated expression that keeps the null values:
ISNULL([<Field>]) OR NOT CONTAINS(LOWER(STR([<Field>])), "<Keyword>")
 

Cause

When performing a keyword search and selecting the Exclude option with a Contains search type (partial match) to filter your data, Tableau generates the following calculation and excludes null values:
NOT CONTAINS(LOWER(STR([<field>])), "<keyword>")
Did this article resolve the issue?