Quantcast
Channel: SQLServerCentral » Data Warehousing » Analysis Services » Latest topics
Viewing all articles
Browse latest Browse all 1341

Apply Sourcecode in SSAS

$
0
0
Goal:Use the KPI [Measures].[Profit Margin] inside of SSAS:s tab named Calculation and then use it in my SSRS report and other userProblem:I tried applying the source code in "Named set" or "calculated set", in SSAS, but it didin't work at all. I don't know how to apply the source code inside of SSAS.Information:*I'm using SQL server 2012*Today, I have the source code in my SSRS report in the query designer view, inside of dataset, but I want the code to be inside of SSAS that I can allow users to use the same source code in their report.*The report's data source is SSAS in my SSRS. MDX code only.*The source code can be used for AdventureWorks.[code="sql"]WITH MEMBER[Measures].[Profit Margin] AS ([Measures].[Internet Sales Amount] - [Measures].[Internet Total Product Cost] ) / [Measures].[Internet Sales Amount] ,FORMAT_STRING="Percent"SELECT { [Measures].[Internet Sales Amount], [Measures].[Internet Total Product Cost], [Measures].[Profit Margin] }ON COLUMNS ,{ [Date].[Calendar].[Calendar Year].&[2007], [Date].[Calendar].[Calendar Year].&[2008] }ON ROWSFROM [Adventure Works][/code]

Viewing all articles
Browse latest Browse all 1341

Trending Articles