dbTalk Databases Forums  

Applying Kpi Filter from with C#

microsoft.public.sqlserver.olap microsoft.public.sqlserver.olap


Discuss Applying Kpi Filter from with C# in the microsoft.public.sqlserver.olap forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Graham Evans
 
Posts: n/a

Default Applying Kpi Filter from with C# - 08-20-2010 , 06:44 AM






Hi all

I am using the Microsoft.AnalysisServices DLL to access my Cubes KPIs. From here I can set a Value, Goal etc.

What I am trying to do now is apply a filter to the KPI, for example all values for the year 2004 and the manufacturer 'Good Year'.

From BIDS I can do this from the browser screen from within the KPI tab.

How can I achieve this from C#? the KPI object doesn't appear to have any filtering properties or methods.

Thanks in advance.

Graham

Submitted via EggHeadCafe - Software Developer Portal of Choice
AJAX Web Service Driven Customers Table With Customer Details
http://www.eggheadcafe.com/tutorials...r-details.aspx

Reply With Quote
  #2  
Old   
Piotr Naszarkowski
 
Posts: n/a

Default Re: Applying Kpi Filter from with C# - 08-23-2010 , 03:23 AM






Hi, you can execute simple MDX query that uses KPIGoal, KPIValue
functions to retrieve value and goal of KPI. In such query you can add
where clause that filters data. It would look like this:

SELECT KPIValue("your kpi") on columns
FROM YourCube
WHERE ([Date].[Year].[Year].&[2010])

Hope this helps,

Piotr

Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.