Extract data from a cube's dimension created from a View

1.3k Views Asked by At

We have imported an SQL View table into a dimension. We already programmed a connector that talks with data cubes (MDX queries). That said, the view we originally imported contains all the raw data we need to query. Problem is, the MDX client requires to "select" measures only. We want to show the raw data, that means, we want to view the same columns\attributes as the initiale SQL View created.

Is this even possible ? We know we can use Linq or whatever to talk with the SQL View Table but it will be better to talk in MDX cube-like mode to a "dumb" cube dimension's data.

Thanks.

1

There are 1 best solutions below

0
On

I don't understand why you really want to use the cube and not your view, but anyway you've two solutions to extract dimension's members from a cube: through a DMV or through a standard MDX query.

The DMV named $system.MdSchema_members will return the members of your dimension. You should be able to retrieve the values you are looking for. http://msdn.microsoft.com/en-us/library/ms126046.aspx

The other solution is to create a dummy measure with a create measure statement above your MDX query. In your SQL statement, then put this dummy measure on axis 0 and all the attributes you're looking for on axis 1. This should return you a result close to the result returned by a select * from your view.