Quantifier

Learn how to use quantity-based filters in event expressions.

Quantifiers let you specify how often an event must occur in order to satisfy an expression. They are useful when you want to check whether an event happened exactly, at least, or at most a certain number of times.

Syntax

The syntax for quantifiers is as follows:

QuantifierDescription
exactly /*<number>*/ timesMatches exactly that number of occurrences.
at least /*<number>*/ timesMatches that number or more.
at most /*<number>*/ timesMatches that number or fewer.

You can use the singular or plural form of "time" regardless of the number specified.

Examples

Check for a specific number of sign-ins:

user has signed in exactly 3 times
Try in Playground

Check if a product was viewed at least twice:

user has viewed a product with name "Sneakers" at least 2 times
Try in Playground

Check if a page was viewed at most once:

user has viewed a page with url like "support" at most 1 time
Try in Playground