title: MDX query to order (and topfilter) results after/with a crossjoin
body: <p>I would like to order a set of results in an MDX query which also includes a crossjoin.</p>
  
  <p>I have the following measures and dimensions:</p>
  
  <ul>
  <li>[Measures].[Starts] </li>
  <li>[Framework].[Framework Name] </li>
  <li>[Framework].[Pathway Name]</li>
  </ul>
  
  <p>I would like to create a list of the (corresponding) Framework and Pathway names that correspond to the top 25 numbers of [Measures].[Starts].</p>
  
  <p>I have managed to output a FULL list of results using:</p>
  
  <pre><code>select [Measures].[Starts] on COLUMNS,
  NON EMPTY CrossJoin(
  Hierarchize({DrilldownLevel({[Framework].[Pathway Name].Children})}), 
  Hierarchize({DrilldownLevel({[Framework].[Framework Name].Children})})
  ) on ROWS
  from [DataCube] 
  </code></pre>
  
  <p>to create the following example output:
  <a href="https://i.stack.imgur.com/I8ckZ.jpg" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/I8ckZ.jpg" alt="example table required"></a></p>
  
  <p>However, I need it to be sorted by the starts in descending order (and preferably only keep the top 25 results).  I have tried almost everything and have failed.  A google search didn't find any results.</p>