[Mondrian] Questions regarding measures and ordinalColumn attributeof Level element

Julian Hyde julianhyde at speakeasy.net
Thu Jul 5 21:17:42 EDT 2007


- Why does jPivot shows a sum of every record of the fact table and not just
the sum of the records that have a foreign key to the dimension ? (i.e. by
analising the query that mondrian produces i see that it does a sum() on the
fact column but does not have a join condition with the dimension table. Why
is that ?  

Two possibilities here. One is that you are not constraining on that
particular dimension. If the context of a dimension is 'all', then mondrian
doesn't bother generating join conditions.
The other possibility is that you are seeing a bug. If your schema has
multiple parent-child dimensions without closure tables that would be fairly
uncommon and it's possible that there is a bug there. If this is the case,
please log a bug at http://sourceforge.net/tracker/?group_id=35302
<http://sourceforge.net/tracker/?group_id=35302&atid=414613> &atid=414613.
A testcase involving a variant of the foodmart schema and an MDX statement
would be preferred. As usual, the better testcase you can provide, the more
likely it is that I will find time to look into it. :)

- The other issue is that the members of the dimensions are not ordered as i
would like them to be. The attribute ordinalColumn on the <Level> element is
being used and the records are fetched correctly with the order by clause
(i'm seeing this on the query logs of mysql), but they're not showing up
correctly in the pivot table. Any ideas ?  

It's probably a mondrian issue, because jpivot just displays the data in the
order it comes back from mondrian. Is your ordinal column numeric or string?
If it's labelled as a string when it should be numeric, or vice versa, the
ordering will be screwed up.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.pentaho.org/pipermail/mondrian/attachments/20070705/b8db9be8/attachment.html 

More information about the Mondrian mailing list