Tableau (IN) operator for calculations
top of page
Bernard K

Tableau (IN) operator for calculations


Tableau In operator

Tableau IN operator is a logical function used to test whether a specified value matches any value in a list of comma-separated values, a set, or combined fields.

(Note: The IN operator supports string, date, numeric and Boolean data types)

IN Syntax

<expr1> IN <expr2>

Where the value of <expr1> can be a set, list on values or combined fields.

Example 1

SUM([Sales]) in (2,297,202, 2,340,789, 3,456,782)

This expression returns TRUE if SUM([Sales]) matches any value in the comma-separated values

Example 2

Example of tableau in operator

(This calculation returns ‘Eastern Africa’ for each country matching the comma-separated values)

I hope this was somewhat helpful to you.

Thank you for reading.

Blog.png
Black & white.jpg

About Me

More About the Author

Bernard K

Analytics Consultant | 3X Tableau Certified

Bernard is a data analytics consultant helping businesses reveal the true power of their data and bring clarity to their reporting dashboards. He loves building things and sharing knowledge on how to build dashboards that drive better outcomes.

Let’s discuss your data challenges! Let’s work together!

bottom of page