Site icon i2tutorials

Amazon QuickSight – endsWith

Amazon QuickSight – endsWith

 

The endsWith function in Amazon QuickSight determines whether a given expression ends with a specified substring. The function takes two required arguments, which are the input expression that you want to check, and the substring that you want to search for, as well as an optional third argument that specifies the comparison mode.

Syntax

#Start#
endsWith(expression, substring, string-comparison-mode)
#End#

 

This function takes three arguments

 

 

The string-comparison-mode parameter can take one of three values

For example, if you have a data set that includes a column for email addresses and you want to filter the data to only include email addresses that end with the substring “@example.com”, you can use the endsWith function with the CASE_INSENSITIVE mode to create a filter expression.

Example

#Start#
endsWith(EmailAddress, "@example.com", "CASE_INSENSITIVE")
#End#

 

This filter expression would return true for all email addresses that end with the substring “@example.com” regardless of the case of the letters.

 

Exit mobile version