Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

question on MDX syntax

0 views
Skip to first unread message

light_wt

unread,
Nov 11, 2009, 3:49:01 PM11/11/09
to
I need help on a simple MDX query. It is to find 1) the latest HeadCount or
2) the HeadCount of today.

Say, if today is aug 15, 2009. the basic query is like:
SELECT
[Measures].[Bills In]
ON 0
,
[Dim Date].[Calendar YrQtMoDt].[Date].&[08]&[2009-08-15T00:00:00]
ON 1

FROM [PTFinancialVendor]

how to change it so it will return the HeadCount from the latest date (non
empty HeadCount), or the HeadCount where the date is today

amish

unread,
Nov 15, 2009, 6:32:16 AM11/15/09
to
On Nov 12, 1:49 am, light_wt <ligh...@discussions.microsoft.com>
wrote:

select [Measures].[Internet Sales Amount] ON 0,
TAIL(FILTER([Date].[Date].MEMBERS,NOT ISEMPTY([Measures].[Internet
Sales Amount])),1)
ON 1
FROM
[Adventure Works]

;


select [Measures].[Internet Sales Amount] ON 0,
TAIL(NONEMPTY([Date].[Date].MEMBERS,[Measures].[Internet Sales
Amount]),1)
ON 1
FROM
[Adventure Works]

Amish Shah

amish

unread,
Nov 15, 2009, 6:34:34 AM11/15/09
to
On Nov 12, 1:49 am, light_wt <ligh...@discussions.microsoft.com>
wrote:

select [Measures].[Internet Sales Amount] ON 0,
TAIL(FILTER([Date].[Date].MEMBERS,NOT ISEMPTY([Measures].[Internet
Sales Amount])),1)
ON 1
FROM
[Adventure Works]

;


select [Measures].[Internet Sales Amount] ON 0,
TAIL(NONEMPTY([Date].[Date].MEMBERS,[Measures].[Internet Sales
Amount]),1)
ON 1
FROM
[Adventure Works]

Amish Shah
http://shahamishm.blogspot.com

0 new messages