[Mondrian] proposal for Order function with key specification list

Rushan Chen rchen at lucidera.com
Tue Sep 2 03:08:16 EDT 2008


Mondrian implements the standard ORDER function as specified here:
http://msdn.microsoft.com/en-us/library/ms145587.aspx

It allows sorting of a set using one sort order based on a  value or 
string expression for each cell.

In our client, we would like to be able to sort a set using not just the 
value_expression for a cell but also the level coordinates, similar to 
the SQL order by clause. For MDX, it looks something like this:

ORDER(<set> {, <key_specification>}...)
<key_specification> ::= {<level>|<value_expression>} [, ASC | DESC | 
BASC | BDESC]
<value_expression> ::= <numeric_value_expression> | 
<string_value_expression>

If <level> is specified, cells are compared using the ordinal column 
value (if CompareSiblingsByOrderKey is set) for that level.

I would like to know if this is something useful to everyone, and 
whether for this it makes sense to extend Mondrian MDX beyond standard MDX.

Thanks!

-- 
Rushan Chen







More information about the Mondrian mailing list