Data filtering

Learn how data filtering works and how to use it to filter your data in the page builder and actions.

Updated over a week ago

Filter parts

A filter consists of three parts: a left-hand side value, an operator or comparator, and a right-hand side value. So you will be able to compare a certain value (or values) on the left with another value (or values) on the right.

Filtering on a data model

This way you can get a subset of all available records.

Left-hand side

On the left, you can select a property of the currently selected model. This can either be a property of that model or the property of a relation of that model. Based on the kind of this selected property we show several operators which are available for this kind of property. For example, when the property is of kind string it makes sense to offer the starts_with operator, but when the property is of kind number it makes sense to offer an operator like is after or at or greater then. So each kind of property has its logical operators.

Operators

As mentioned in the section about the left-hand side, we offer a set of operators for each kind of property.

Property kind

Operator group

  • boolean

  • boolean_expression

boolean_operators

  • equals

  • is not equal to

  • date

  • date_expression

  • date_time

  • date_time_expression

  • time

date_operators

  • equals

  • is not equal to

  • is before

  • is after

  • is before or equal to

  • is after or equal to

  • decimal

  • decimal_expression

  • integer

  • integer_expression

  • serial

integer_operators

  • equals

  • is not equal to

  • is greater than

  • is less than

  • is greater than or equal to

  • is less than or equal to

  • list

list_operators

  • equals

  • is not equal to

  • string

  • string_expression

string_operators

  • equals

  • is not equal to

  • starts with

  • ends with

  • contains

  • matches with

  • does not match with

Right-hand side

On the right-hand side of a filter, you can select a property/variable/value to compare the left-hand side with.

Applying the filter in the page builder

When you have selected a date or datetime on the left-hand side, we offer relative values as well. Those can be:

  • Today

  • Yesterday

  • Tomorrow

  • Day before yesterday

  • Day after tomorrow

  • Three days ago

  • This week

  • Last week

  • Next week

  • This month

  • Last month

  • Next month

  • This year

  • Last year

  • Next year

When one of those values is chosen, we will calculate the date / datetime at runtime and use it in your filter.

Applying multiple filters

Sometimes, or maybe often, filtering by just one property is not enough. Mostly, you will want to be able to set a more specific filter. Let's say, you want to see the tasks of one user for this week. You can’t do this with one filter, because it will give you the tasks of this week, or the tasks assigned to a particular user.

In that case, you can use another filter row. In even more complex filtering, you might even need groups with one or more filter rows each.

Multiple filter rules

As mentioned above, when you want to have a more specific filter, you can add more filter rules. Each rule will compare a property with a certain value. For example when you want to show the table with users with active accounts who created them (registered) after a certain date and time and have an admin role.

Adding multiple filter rules

Filter groups

When multiple filter rules are still not enough, you can use filter groups. For example,

take these two filter groups: the data table will either show reminders that have been created after last month with the status of 'In progress' OR any reminder that has been created by an admin. Groups consist of one or more rules.

When using groups there is another operator which is important - the AND/OR operator. You can apply this operator between filter groups.

Applying filter groups

AND/OR operator

Then AND/OR operator can be used in between filter rules. It says to either meet the criteria in both rows or meet the criteria mentioned in one or both rows.

In this example, we set two rules for the condition step: to be able to proceed with the 'True' condition flow, users would need to have either one or a second email address.

Filter group example

Did this answer your question?