Site icon i2tutorials

Amazon QuickSight – notIn

Amazon QuickSight – notIn

 

The ‘notIn’ function in Amazon QuickSight checks whether a given expression is not in a specified list of literals.

Syntax

#Start#
notIn(expression, [literal-1, ...])
#End#

 

This function takes two arguments:

 

 

 

Suppose you have a dataset containing a list of products with their names, categories, and prices, and you want to create a filter that excludes products in a specific category.

 

Assume the following dataset:

 

Product NameCategoryPrice
Product ACategory 1$10
Product BCategory 2$20
Product CCategory 1$15
Product DCategory 3$25
Product ECategory 2$30

 

To exclude products in Category 1, you can create a filter using the notIn function:

 

 

Example

#Start#
notIn({Category}, 'Category 1')
#End#

 

This will create a filter that excludes any products with the Category value of “Category 1”.

 

After applying this filter, only products with Category values other than “Category 1” will be displayed in the visual. In this example, Products B, D, and E will be displayed, and Products A and C will be excluded.

 

Exit mobile version