![]() | |
![]() |
| | Thread Tools | Display Modes |
#1
| |||
| |||
|
#2
| |||
| |||
|
|
i have a time dimension with years, quarters, and months in a report I need to show the last 2 months, then the last 2 quarters, then the last 2 years, each in descending order. I use this query to pull them {LastPeriods(2,[FiscalDate].LastChild.LastChild.LastChild),LastPeriods(2,[Fi |
| my new year starts in march, so right now this query returns (in this order): feb 2005, march 2006, quarter 4 2005, quarter 1 2006, 2005, 2006 i need the query to return each "subset" in descending order, so my results look like this march 2006, feb 2005, quarter 1 2006, quarter 4 2005, 2006, 2005 I've tried different arguments to the order function but have been unsucessful so far. thanks! |
#3
| |||
| |||
|
|
{ Order(LastPeriods(2,[FiscalDate].LastChild.LastChild.LastChild), [FiscalDate].CurrentMember.Properties("ID"), BDESC) , Order(LastPeriods(2,[FiscalDate].LastChild.LastChild), [FiscalDate].CurrentMember.Properties("ID"), BDESC) , Order(LastPeriods(2,[FiscalDate].LastChild), [FiscalDate].CurrentMember.Properties("ID"), BDESC) } or Order({LastPeriods(2,[FiscalDate].LastChild), LastPeriods(2,[FiscalDate].LastChild.LastChild), LastPeriods(2,[FiscalDate].LastChild.LastChild.LastChild)} AS SetA, Rank([FiscalDate].CurrentMember, SetA), BDESC ) Ohjoo Kwon "Paul" <Paul (AT) discussions (DOT) microsoft.com> wrote in message news:1DE60272-AF24-4AD7-9B80-1E8B8A331952 (AT) microsoft (DOT) com... i have a time dimension with years, quarters, and months in a report I need to show the last 2 months, then the last 2 quarters, then the last 2 years, each in descending order. I use this query to pull them {LastPeriods(2,[FiscalDate].LastChild.LastChild.LastChild),LastPeriods(2,[Fi scalDate].LastChild.LastChild),LastPeriods(2,[FiscalDate].LastChild)} my new year starts in march, so right now this query returns (in this order): feb 2005, march 2006, quarter 4 2005, quarter 1 2006, 2005, 2006 i need the query to return each "subset" in descending order, so my results look like this march 2006, feb 2005, quarter 1 2006, quarter 4 2005, 2006, 2005 I've tried different arguments to the order function but have been unsucessful so far. thanks! |
![]() |
| Thread Tools | |
| Display Modes | |
| |