1

How do i filter, in a Mondrian MDX Query, just the FACTS that have ocurred in a Range of Months over last 3 years?

I need to make it dynamic so i can use parameters latter, so i need the following:

Month Range over last 3 years, Where StartMonth and EndMonth is given by user by parameters.

[2002].[January], [2002].[February], [2002].[March] [2003].[January], [2003].[February], [2003].[March] [2004].[January], [2004].[February], [2004].[March] 

Time dim have Year, Half Year, Quarter, Month, Week and Day level.

I have tryed this, but i get an error Mondrian Error:Cannot deduce type of set

WITH set [MesesFiltrados] as DESCENDANTS( FILTER(LastPeriods (3, StrToMember("[Data].[" || TRIM(Str(Int(YEAR(NOW())))) || "]") ), [Data].[Mes].currentmember in ([Data].Mes.[${StartMonth}]:[Data].Mes.[${StartMonth}]) ) ) Select {[Escritorio]} on columns, { MesesFiltrados } on rows From Desempenho 

Tks

0

0

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.