All eazyBI for Jira eazyBI for Confluence Private eazyBI

Lag

Returns the member with a specified number of positions before a specified member along the member's dimension.

Mostly used with Aggregate when created as calcualted members in the Time dimension or with a measure when used for calcualted measures.

Syntax

Member_Expression.Lag(index)

Arguments

Member_ExpressionMDX expression that returns a member
indexMDX expression that specifies the number of member positions to lag.

Examples

The following example returns the month-level member from Time dimension 4 periods before the current month (*If I run this calculation in Dec'2024, it will return Sep'2024)

[Time].[Month].CurrentDateMember.Lag(4)


The next example will find the Q2 2023 which was three quarters before Q1'2024

[Time].[2024].[Q1 2024].Lag(3)


This example will find the year 2024 which is 0 years before the specified year.

[Time].[2024].Lag(0)


The last example will find the Mar 2023 which is two months after Jan 2023

[Time].[2023].[Q1 2023].[Jan 2023].Lag(-2)

See also