title: Mondrian Rollup Total with a dimension
body: <p>I want mondrian to rollup as per my dimension table. For example</p>
  
  <p>fact_table(id int, dim_id)</p>
  
  <ul>
  <li>1 2</li>
  <li>2 2</li>
  <li>3 1</li>
  <li>4 3</li>
  </ul>
  
  <p>dimension_table( dim_id, value)</p>
  
  <ul>
  <li>1 first_value</li>
  <li>2 second_value</li>
  </ul>
  
  <p>The last value in fact_table is delibrately not in the list of dimensions</p>
  
  <pre><code>&lt;Cube name="BYT"&gt;
           &lt;Dimension type="StandardDimension" visible="true" 
                     highCardinality="false" name="d1"&gt;
      &lt;Hierarchy name="dimension_table" visible="true" hasAll="true"&gt;
        &lt;Table name="dimension_table"&gt;
        &lt;/Table&gt;
        &lt;Level name="dimension" visible="true" column="dim_id" 
              type="String" uniqueMembers="false" levelType="Regular" 
                    hideMemberIf="Never"&gt;
        &lt;/Level&gt;
      &lt;/Hierarchy&gt;
    &lt;/Dimension&gt;
       &lt;Measure name="m1"  column="id"  datatype="Integer" 
             aggregator="count" visible="true"&gt;
      &lt;/Measure&gt;
      &lt;Cube&gt;
  </code></pre>
  
  <p>when i fire the following query </p>
  
  <pre><code>select [Measure].[m1] on columns, {([d1])} on rows from [BYT]
  </code></pre>
  
  <p>The result is </p>
  
  <pre><code> - Dimension  Measure
   - All D1     4
  </code></pre>
  
  <p>What i would like mondrian to do is something like this </p>
  
  <pre><code>- Dimension  Measure
  - All D1     3
  </code></pre>
  
  <p>i.e. count only on the values included in the dimension table</p>
  
  <p>Please suggest a solution. I read through the rollup policy in the documentation but that does not help my case. </p>