Wednesday, March 7, 2012

Hierarchize and Descendants functions...

I am having an issue getting these two functions to work together. Can someone please advise me what I am doing wrong. Keep in mind this is being executed in Visual Studio to the results are sometimes different than SQL Server Management Studio. The problem is they are being sorted correctly after I removed the descendants function.

Code Snippet

SELECT

NON EMPTY {[Measures].[Avg Answer] } ON COLUMNS,

NON EMPTY { hierarchize(descendants([Lot].[HomeBuilder Organization].[ALL],4)) }

DIMENSION PROPERTIES MEMBER_CAPTION, MEMBER_UNIQUE_NAME ON ROWS

FROM [Customer Loyalty Analytics] CELL PROPERTIES VALUE, BACK_COLOR, FORE_COLOR, FORMATTED_VALUE, FORMAT_STRING, FONT_NAME, FONT_SIZE, FONT_FLAGS

Hierarchize function is a no-op here, since the result of Descendants is already hierarchized.

No comments:

Post a Comment