0
votes

I have the following query created on SQL Management studio and I'm trying to use it in a Calculated Measure in Excel:

SELECT NON EMPTY { [Measures].[Net Cash Invoice Sales] } ON COLUMNS 
FROM ( SELECT ( { [Customer].[Customer Type].&[Existing Guest] } ) ON COLUMNS 
FROM [Model]) WHERE ( [Customer].[Customer Type].&[Existing Guest] )

I have tried different options but cant get the right syntax so it works in Excel MDX. The Measure is a simple selection of Invoices by a customer type.

so something like: [Measures].[Net Cash Invoice Sales] WHERE ( [Customer].[Customer Type].&[Existing Guest] )

I tried using Functions like Filter but no go:

Filter ( [Measures].[Net Cash Invoice Sales] , [Customer].[Customer Type].&[Existing Guest] )

1

1 Answers

0
votes

Who knew it could be so simple?

([Measures].[Net Cash Invoice Sales],
[Customer].[Customer Type].[Existing Guest])

Got the idea from Define a calculated member in MDX by filtering a measure's value