All eazyBI for Jira eazyBI for Confluence Private eazyBI

Cache

Caches the result of the calculation in memory per context for report execution. It can be useful when the same calculation is repeated in the report more than once in the same context.

Syntax

 Cache(Expression)

Examples


A report has a measure that for calculation uses the result of a previously calculated measure. Using cache would store the first time calculation result in memory and for the next measure would be used to optimize the performance of the report.

A default measure in Jira issue cube Open issues uses cache function for performance improvements as the query should go through all time members and repeat the mathematical expression to each of them.


Cache(
    NonZero(Sum(PreviousPeriods([Time].CurrentHierarchyMember),
      Cache([Measures].[Issues created]
          - [Measures].[Issues resolved])
    ))
    + [Measures].[Issues created]
    - [Measures].[Issues resolved]
  )

See sample report Created vs resolved issues over time in our Demo account. Measure Open issues contains the formula above.