Multiple filter rules with OR statements
Now let’s look at an OR statement that contains multiple filter rules on each side of the OR. This uses the same two rules as before but adds a rule—projects also must have a Current status.
Notice that Workfront “grouped” the filter rules on each side of the OR (there’s a gray box around them). This tells Workfront to run the rules on each side of the OR together, finding projects that meet both of those criteria because they’re joined with AND.
In this example, Workfront looks for:
- Projects that have your name in the project owner field that also have a status of Current.
- PLUS (OR)
- Projects that you created that also have a status of Current.
Putting the “project status equals Current” rule on each side of the OR ensures that rule works in conjunction with each of the other rules. This common rule is sometimes referred to as the “constant.”
What happens without the common filter rule?
Without the common filter rule(s), you may not get the search results you anticipated.
For example, if you put the “project status equals Current” rule only on one side of the OR, it only works with the other filter rules in that section. In the image below, you see the “project status equals Current” rule is in the top section only.
This means Workfront will look for:
- Projects that have your name in the project owner field and have a status of Current.
- PLUS (OR)
- All projects you created.
As you can see, this filter setup gives you slightly different results than the filter with the repeated filter rule. That’s why making sure the filter is set up properly is important to ensuring you’re getting the results you want and need.
You may not use OR statements frequently when creating filters. But doing so might help you reduce the number of filters you need to create. Just make sure that your filters don’t return too many results—a long list can make finding the exact information needed more difficult for users.