Showing posts with label cube. Show all posts
Showing posts with label cube. Show all posts

Wednesday, March 21, 2012

Matrix SSAS dimension/hierarchy order problem

I have a have a relatively simple SSAS cube that I'm trying to display in a matrix but the order of the data is not correct. The rows of the matrix are a time hierarchy and the query designer produces the correct MDX and when I run the MDX in the data tab, the order is correct. However in the report preview tab, the order is incorrect. Specifically, the time hierarchy looks like this Year-Month-FullDate. The report is ordering the Months like this 1,10,11,12,2,3,4,5,6,7,8,9. I ran the MDX query in Sql Studio and the order is correct, and I used Excel to consume the same cube and it produces the correct order.

The report is somehow treating the Month like character data instead of numeric, how do I fix this?

It sounds like your MDX query only retrieves the Member_Caption (which is the string label representation), but not the Member_Value property (which is the value representation with the original data type).

For example:

SELECT NON EMPTY { [Measures].[Sales Amount] } ON COLUMNS, NON EMPTY { ([Due Date].[Month Number Of Year].[Month Number Of Year].ALLMEMBERS * [Due Date].[English Month Name].[English Month Name].ALLMEMBERS ) } DIMENSION PROPERTIES MEMBER_CAPTION, MEMBER_UNIQUE_NAME, MEMBER_VALUE ON ROWS FROM [Adventure Works DW] CELL PROPERTIES VALUE, BACK_COLOR, FORE_COLOR, FORMATTED_VALUE, FORMAT_STRING, FONT_NAME, FONT_SIZE, FONT_FLAGS

Note that the .Value field property of RDL expressions always maps to the Member_Caption property value for dimensions (the member caption is always a string!). The additional Member_Value intrinsic dimension property is not mapped directly to any of the predefined RDL extended field property names. Therefore, in order to access the MEMBER_VALUE property in the report, you have to use the so-called field property collection syntax in the matrix group expression and sort expression to get the numeric value for the dimension property and specify the property name exactly as defined in the MDX query above (the property name is case-sensitive in this case):
=Fields!Month_Number_Of_Year("MEMBER_VALUE")

Additional information about MDX intrinsic member properties can be found here: http://msdn2.microsoft.com/en-us/library/ms145528.aspx

-- Robert

|||

Robert - that worked perfectly. Thanks a bunch!

To anyone else in the same situation, to get to the matrix group expression and sort expression right-click the matrix object in the report designer and select Properties. Goto the Groups tab and then select dimension member in question and click the Edit button. This brings up another window, goto the Sort tab and enter the expression.

Monday, March 12, 2012

Matrix Control Reports...

Hi Folks,
I am in the process of creating MSRS 2005 reports which run of a MSAS cube.
I have 2 matrix controls which feed of 2 different datasets. There are 3
columns in each matrix control which are part of a hierarchy. when the user
drills down a parent on the first control, is it possible for the child on
the second matrix control to be also visible.
For example when user clicks on the + sign before "A", "B" is made visible
on first matrix, at the same time "B" should be visible on the second matrix.
2. I have 2 matrix controls side by side, i have to show and hide the 2
based on a report parameter. Is it possible to dynamically alter the location
of the matrix control on the report. For example if the 1st matrix control is
made invisible, can i move 2 matrix control to take the place of the first
matrix cntrol.
Thank you
RamdasHi Ram,
I have the same problem (your second) - I want to decide the location of
the Matrix dynamically at run time. (Reporting Services)
If you've come to a solution, kindly contact me
DAVIDMA4@.YAHOO.COM
David
--
×?×?×?
"Ram" wrote:
> Hi Folks,
> I am in the process of creating MSRS 2005 reports which run of a MSAS cube.
> I have 2 matrix controls which feed of 2 different datasets. There are 3
> columns in each matrix control which are part of a hierarchy. when the user
> drills down a parent on the first control, is it possible for the child on
> the second matrix control to be also visible.
> For example when user clicks on the + sign before "A", "B" is made visible
> on first matrix, at the same time "B" should be visible on the second matrix.
> 2. I have 2 matrix controls side by side, i have to show and hide the 2
> based on a report parameter. Is it possible to dynamically alter the location
> of the matrix control on the report. For example if the 1st matrix control is
> made invisible, can i move 2 matrix control to take the place of the first
> matrix cntrol.
> Thank you
> Ramdas
>

Friday, March 9, 2012

Matrix Aggregation to a Column only

Hello,
I have a matrix report displaying data from a data cube, via analysis
services. It contains column groupings for Months, Quarters and Year as well
as row groups for Team, User and Region. This allows the user to drill down
from a top level "All Teams" total for the whole year, down to a full view of
a region for a particular month.
To achieve this, the "Sum" function is used to aggregate the figures. But,
we wish to also use a running total of Sales by region using Brought Forward
and Carried Forward balances. This needs to be aggregated by column (region
to user to team), but not by row. (Otherwise the Jan, Feb and March totals
are added together for example for Q1, which is incorrect).
Is there a way to specify the axis for the Sum function? Or another way to
create the report that still allows the drill-down/up functionality?
Many Thanks.
Ben Mann.Although I don't understand the business part of your question... Matrix
allows aggregations to be done on rows OR columns... It looks like you
wanted some aggregation on both axes... Matrixes can do this...
Also you can use any of the aggregate functions that RS supports, take a
look at runningvalue... that might be what you are lookin for...
--
Wayne Snyder, MCDBA, SQL Server MVP
Mariner, Charlotte, NC
www.mariner-usa.com
(Please respond only to the newsgroups.)
I support the Professional Association of SQL Server (PASS) and it's
community of SQL Server professionals.
www.sqlpass.org
"Ben Mann" <Ben Mann@.discussions.microsoft.com> wrote in message
news:37B6B96A-FF6F-4D63-A820-B6E588C13233@.microsoft.com...
> Hello,
> I have a matrix report displaying data from a data cube, via analysis
> services. It contains column groupings for Months, Quarters and Year as
well
> as row groups for Team, User and Region. This allows the user to drill
down
> from a top level "All Teams" total for the whole year, down to a full view
of
> a region for a particular month.
> To achieve this, the "Sum" function is used to aggregate the figures. But,
> we wish to also use a running total of Sales by region using Brought
Forward
> and Carried Forward balances. This needs to be aggregated by column
(region
> to user to team), but not by row. (Otherwise the Jan, Feb and March totals
> are added together for example for Q1, which is incorrect).
> Is there a way to specify the axis for the Sum function? Or another way to
> create the report that still allows the drill-down/up functionality?
> Many Thanks.
> Ben Mann.

Wednesday, March 7, 2012

Materializing the cubes, absence of CREATE CUBE

Hi all,

(1) Does making a cube through Cube Wizard in Visual Studio imply materialiing the view
in a database?

I created a cube in AdventureWorksDW sample database. There is no error after I
deployed the project. Still the size of data files and transaction-log files of database
remain the same.

(2) Is the cube materialized? Can we materialize cubes?

(3) Shall Microsoft introduce operation CREATE CUBE in the MDX? I saw only
ALTER CUBE, CREATE SUBCUBE, and DROP SUBCUBE in online book.

Thank you,

Bernaridho

1) No

2) Yes, you can take the cubes offline

3) http://msdn2.microsoft.com/en-us/library/ms145581.aspx

Saturday, February 25, 2012

Materialized reference dimensions

I have a cube that has a chain ofreferenced dimensions in it. Analysis Services says all the dimensions in the chain must be "materialized". In fact, it demands it. But when I set them to "materialized", the cube won't process. I get this error message:


Errors in the OLAP storage engine: An error occurred while processing the '2004Trx' partition of the 'Membership Counts' measure group for the 'Memberships' cube from the DimensionsOnly database.

I'm stuck. Anyone have any ideas on how to get around this?

Thanks.

Are there more messages you are getting along with one you mention above?

Is there missing key or something like that?

Edward.
--
This posting is provided "AS IS" with no warranties, and confers no rights.