|
Home > Archive > MS SQL Server OLAP > December 2005 > Extracting first month
You are viewing an archived Text-only version of the thread.
To view this thread in it's original format and/or if you want to reply to
this thread please [click here]
| Author |
Extracting first month
|
|
| Denver 2005-12-20, 9:24 am |
| I have this qry
WITH
SET [LatestMonth] AS
'TAIL(NONEMPTYCROSSJ
OIN([Time].[Standard].[Month].Members,
{[Country].[Country].[Bahrain]}, 1), 1)'
SELECT
{[Measures].[Coverage]} ON 0,
CROSSJOIN({[Country].[Country].[Bahrain]}, [LatestMonth]) ON 1
FROM [Cross Country]
This succesfully gets me the last month, what can I do to get the first
month. (i.e. the opposite to tail)
Thanks
Denver
| |
|
| Hi Denver,
The Function opposite to TAIL is HEAD.
Ta
Paul
"Denver" wrote:
> I have this qry
>
> WITH
> SET [LatestMonth] AS
> 'TAIL(NONEMPTYCROSSJ
OIN([Time].[Standard].[Month].Members,
> {[Country].[Country].[Bahrain]}, 1), 1)'
> SELECT
> {[Measures].[Coverage]} ON 0,
> CROSSJOIN({[Country].[Country].[Bahrain]}, [LatestMonth]) ON 1
> FROM [Cross Country]
>
> This succesfully gets me the last month, what can I do to get the first
> month. (i.e. the opposite to tail)
>
> Thanks
>
> Denver
>
>
|
|
|
|
|