Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Migrated to Confluence 5.3

Function: Unmatched

Syntax

Code Block
languagenone
Unmatched()

Description

Unmatched is a special function which returns true if the value has not matched any of the previous facets, it does not accept any arguments.

To illustrate - if there were 3 requirements, each with different priorities:

  • Requirement A - Priority: High
  • Requirement B - Priority: Low
  • Requirement C - Priority: Medium

We could write a Faceted aggregation expression:

Code Block
languagenone
Faceted Equal(Priority, High) AS 'Urgent',
        OrArgs(Equal(Priority, Low), Equal(Priority, Medium)) AS 'Non-Urgent'
{
   COUNT
}
WHERE EntityType = Requirement

But if we add more non-high priorities to the picklist over time, we will need to update our faceted query to then capture those values.

As an alternative we could just write this:

Code Block
languagenone
Faceted Equal(Priority,High) as 'Urgent',
        Unmatched() as 'Non-Urgent'
{
   COUNT
}
WHERE EntityType = Requirement

In this case anything that doesn't match urgent will be "unmatched" and fall through to the "Unmatched()" facet.