<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML xmlns="http://www.w3.org/TR/REC-html40" xmlns:o =
"urn:schemas-microsoft-com:office:office" xmlns:w =
"urn:schemas-microsoft-com:office:word"><HEAD>
<META http-equiv=Content-Type content="text/html; charset=us-ascii">
<META content="MSHTML 6.00.6001.18023" name=GENERATOR>
<STYLE>
<!--
/* Font Definitions */
@font-face
        {font-family:Verdana;
        panose-1:2 11 6 4 3 5 4 4 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0in;
        margin-bottom:.0001pt;
        font-size:12.0pt;
        font-family:"Times New Roman";}
a:link, span.MsoHyperlink
        {color:blue;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {color:purple;
        text-decoration:underline;}
span.EmailStyle17
        {mso-style-type:personal-compose;
        font-family:Verdana;
        color:windowtext;
        font-weight:normal;
        font-style:normal;
        text-decoration:none none;}
@page Section1
        {size:8.5in 11.0in;
        margin:1.0in 1.25in 1.0in 1.25in;}
div.Section1
        {page:Section1;}
-->
</STYLE>
</HEAD>
<BODY lang=EN-US vLink=purple link=blue>
<DIV dir=ltr align=left><SPAN class=855063504-13052008><FONT face=Verdana
color=#000080 size=2>Timothy,</FONT></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=855063504-13052008><FONT face=Verdana
color=#000080 size=2></FONT></SPAN> </DIV>
<DIV dir=ltr align=left><SPAN class=855063504-13052008><FONT face=Verdana
color=#000080 size=2>Thanks. I have checked in your change as
11055.</FONT></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=855063504-13052008><FONT face=Verdana
color=#000080 size=2></FONT></SPAN> </DIV>
<DIV dir=ltr align=left><SPAN class=855063504-13052008><FONT face=Verdana
color=#000080 size=2>You didn't provide an explicit test case, but it was easy
enough to reproduce. For the record, I noticed that this bug reproduced on
FunctionTest.testAggregate2() if I made the Store dimension
high-cardinality.</FONT></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=855063504-13052008><FONT face=Verdana
color=#000080 size=2></FONT></SPAN> </DIV>
<DIV dir=ltr align=left><SPAN class=855063504-13052008><FONT face=Verdana
color=#000080 size=2>Jorge & Luis,</FONT></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=855063504-13052008><FONT face=Verdana
color=#000080 size=2></FONT></SPAN> </DIV>
<DIV dir=ltr align=left><SPAN class=855063504-13052008><FONT face=Verdana
color=#000080 size=2>As part of that change, I added a property
mondrian.test.highCardDimensions to make testing easier. If you set this
property to, say mondrian.test.highCardDimensions=Gender,Store,Customers and run
the test suite it will preprocess the FoodMart.xml to make those dimensions high
cardinality. </FONT></SPAN><SPAN class=855063504-13052008><FONT face=Verdana
color=#000080 size=2>This turns up lots of errors.</FONT></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=855063504-13052008><FONT face=Verdana
color=#000080 size=2></FONT></SPAN> </DIV>
<DIV dir=ltr align=left><SPAN class=855063504-13052008><FONT face=Verdana
color=#000080 size=2>We need the test suite to pass </FONT></SPAN><SPAN
class=855063504-13052008><FONT face=Verdana color=#000080 size=2>regardless of
which dimensions are high-cardinality. I don't think there are any dimensions
for which it currently passes. If there are, let me know and I will add the
property setting to my nightly regress.</FONT></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=855063504-13052008><FONT face=Verdana
color=#000080 size=2></FONT></SPAN> </DIV>
<DIV dir=ltr align=left><SPAN class=855063504-13052008><FONT face=Verdana
color=#000080 size=2>Julian</FONT></SPAN></DIV><BR>
<BLOCKQUOTE dir=ltr
style="PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #000080 2px solid; MARGIN-RIGHT: 0px">
<DIV class=OutlookMessageHeader lang=en-us dir=ltr align=left>
<HR tabIndex=-1>
<FONT face=Tahoma size=2><B>From:</B> mondrian-bounces@pentaho.org
[mailto:mondrian-bounces@pentaho.org] <B>On Behalf Of
</B>timothy.lambert@thomsonreuters.com<BR><B>Sent:</B> Monday, May 12, 2008
5:29 PM<BR><B>To:</B> mondrian@pentaho.org<BR><B>Subject:</B> [Mondrian] Bug
in Large Dimension Handling First Cut<BR></FONT><BR></DIV>
<DIV></DIV>
<DIV class=Section1>
<P class=MsoNormal><FONT face=Verdana size=2><SPAN
style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana">Turning on the “highCardinality”
switch for the Product dimension in FoodMart causes a cast
exception.<o:p></o:p></SPAN></FONT></P>
<P class=MsoNormal><FONT face=Verdana size=2><SPAN
style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"><o:p> </o:p></SPAN></FONT></P>
<P class=MsoNormal><FONT face=Verdana size=2><SPAN
style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana">The problem was that
HighCardSqlTupleReader.readTuples was returning a list of Member[] not a list
of RolapMember[].<o:p></o:p></SPAN></FONT></P>
<P class=MsoNormal><FONT face=Verdana size=2><SPAN
style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"><o:p> </o:p></SPAN></FONT></P>
<P class=MsoNormal><FONT face=Verdana size=2><SPAN
style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana">Fix
attached.<o:p></o:p></SPAN></FONT></P>
<P class=MsoNormal><FONT face=Verdana size=2><SPAN
style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"><o:p> </o:p></SPAN></FONT></P>
<P class=MsoNormal><FONT face=Verdana size=2><SPAN
style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana">Example exception
stack…<o:p></o:p></SPAN></FONT></P>
<P class=MsoNormal><FONT face=Verdana size=2><SPAN
style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"><o:p> </o:p></SPAN></FONT></P>
<P class=MsoNormal><FONT face="Courier New" color=red size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: red; FONT-FAMILY: 'Courier New'">Caused by:
</SPAN></FONT><U><FONT face="Courier New" color=navy size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: navy; FONT-FAMILY: 'Courier New'">java.lang.ClassCastException</SPAN></FONT></U><FONT
face="Courier New" color=red size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: red; FONT-FAMILY: 'Courier New'">:
[Lmondrian.olap.Member; cannot be cast to
[Lmondrian.rolap.RolapMember;</SPAN></FONT><FONT face="Courier New"
size=2><SPAN
style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'"><o:p></o:p></SPAN></FONT></P>
<P class=MsoNormal><FONT face="Courier New" color=red size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: red; FONT-FAMILY: 'Courier New'">
at mondrian.rolap.SqlMemberSource$1$1.next(</SPAN></FONT><U><FONT
face="Courier New" color=navy size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: navy; FONT-FAMILY: 'Courier New'">SqlMemberSource.java:485</SPAN></FONT></U><FONT
face="Courier New" color=red size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: red; FONT-FAMILY: 'Courier New'">)</SPAN></FONT><FONT
face="Courier New" size=2><SPAN
style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'"><o:p></o:p></SPAN></FONT></P>
<P class=MsoNormal><FONT face="Courier New" color=red size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: red; FONT-FAMILY: 'Courier New'">
at mondrian.rolap.SqlMemberSource$1$1.next(</SPAN></FONT><U><FONT
face="Courier New" color=navy size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: navy; FONT-FAMILY: 'Courier New'">SqlMemberSource.java:1</SPAN></FONT></U><FONT
face="Courier New" color=red size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: red; FONT-FAMILY: 'Courier New'">)</SPAN></FONT><FONT
face="Courier New" size=2><SPAN
style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'"><o:p></o:p></SPAN></FONT></P>
<P class=MsoNormal><FONT face="Courier New" color=red size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: red; FONT-FAMILY: 'Courier New'">
at
mondrian.rolap.RolapCubeHierarchy$CacheRolapCubeHierarchyMemberReader.getMembersInLevel(</SPAN></FONT><U><FONT
face="Courier New" color=navy size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: navy; FONT-FAMILY: 'Courier New'">RolapCubeHierarchy.java:627</SPAN></FONT></U><FONT
face="Courier New" color=red size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: red; FONT-FAMILY: 'Courier New'">)</SPAN></FONT><FONT
face="Courier New" size=2><SPAN
style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'"><o:p></o:p></SPAN></FONT></P>
<P class=MsoNormal><FONT face="Courier New" color=red size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: red; FONT-FAMILY: 'Courier New'">
at mondrian.rolap.RolapSchemaReader.getLevelMembers(</SPAN></FONT><U><FONT
face="Courier New" color=navy size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: navy; FONT-FAMILY: 'Courier New'">RolapSchemaReader.java:447</SPAN></FONT></U><FONT
face="Courier New" color=red size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: red; FONT-FAMILY: 'Courier New'">)</SPAN></FONT><FONT
face="Courier New" size=2><SPAN
style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'"><o:p></o:p></SPAN></FONT></P>
<P class=MsoNormal><FONT face="Courier New" color=red size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: red; FONT-FAMILY: 'Courier New'">
at mondrian.rolap.RolapSchemaReader.getLevelMembers(</SPAN></FONT><U><FONT
face="Courier New" color=navy size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: navy; FONT-FAMILY: 'Courier New'">RolapSchemaReader.java:430</SPAN></FONT></U><FONT
face="Courier New" color=red size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: red; FONT-FAMILY: 'Courier New'">)</SPAN></FONT><FONT
face="Courier New" size=2><SPAN
style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'"><o:p></o:p></SPAN></FONT></P>
<P class=MsoNormal><FONT face="Courier New" color=red size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: red; FONT-FAMILY: 'Courier New'">
at
mondrian.rolap.RolapCube$RolapCubeSchemaReader.getLevelMembers(</SPAN></FONT><U><FONT
face="Courier New" color=navy size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: navy; FONT-FAMILY: 'Courier New'">RolapCube.java:2425</SPAN></FONT></U><FONT
face="Courier New" color=red size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: red; FONT-FAMILY: 'Courier New'">)</SPAN></FONT><FONT
face="Courier New" size=2><SPAN
style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'"><o:p></o:p></SPAN></FONT></P>
<P class=MsoNormal><FONT face="Courier New" color=red size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: red; FONT-FAMILY: 'Courier New'">
at mondrian.olap.DelegatingSchemaReader.getLevelMembers(</SPAN></FONT><U><FONT
face="Courier New" color=navy size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: navy; FONT-FAMILY: 'Courier New'">DelegatingSchemaReader.java:139</SPAN></FONT></U><FONT
face="Courier New" color=red size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: red; FONT-FAMILY: 'Courier New'">)</SPAN></FONT><FONT
face="Courier New" size=2><SPAN
style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'"><o:p></o:p></SPAN></FONT></P>
<P class=MsoNormal><FONT face="Courier New" color=red size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: red; FONT-FAMILY: 'Courier New'">
at
mondrian.olap.Query$QuerySchemaReader.getLevelMembers(</SPAN></FONT><U><FONT
face="Courier New" color=navy size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: navy; FONT-FAMILY: 'Courier New'">Query.java:1472</SPAN></FONT></U><FONT
face="Courier New" color=red size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: red; FONT-FAMILY: 'Courier New'">)</SPAN></FONT><FONT
face="Courier New" size=2><SPAN
style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'"><o:p></o:p></SPAN></FONT></P>
<P class=MsoNormal><FONT face="Courier New" color=red size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: red; FONT-FAMILY: 'Courier New'">
at mondrian.olap.fun.FunUtil.getNonEmptyLevelMembers(</SPAN></FONT><U><FONT
face="Courier New" color=navy size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: navy; FONT-FAMILY: 'Courier New'">FunUtil.java:1803</SPAN></FONT></U><FONT
face="Courier New" color=red size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: red; FONT-FAMILY: 'Courier New'">)</SPAN></FONT><FONT
face="Courier New" size=2><SPAN
style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'"><o:p></o:p></SPAN></FONT></P>
<P class=MsoNormal><FONT face="Courier New" color=red size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: red; FONT-FAMILY: 'Courier New'">
at mondrian.olap.fun.FunUtil.levelMembers(</SPAN></FONT><U><FONT
face="Courier New" color=navy size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: navy; FONT-FAMILY: 'Courier New'">FunUtil.java:1812</SPAN></FONT></U><FONT
face="Courier New" color=red size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: red; FONT-FAMILY: 'Courier New'">)</SPAN></FONT><FONT
face="Courier New" size=2><SPAN
style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'"><o:p></o:p></SPAN></FONT></P>
<P class=MsoNormal><FONT face="Courier New" color=red size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: red; FONT-FAMILY: 'Courier New'">
at
mondrian.olap.fun.BuiltinFunTable$34$1.evaluateMemberList(</SPAN></FONT><U><FONT
face="Courier New" color=navy size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: navy; FONT-FAMILY: 'Courier New'">BuiltinFunTable.java:1064</SPAN></FONT></U><FONT
face="Courier New" color=red size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: red; FONT-FAMILY: 'Courier New'">)</SPAN></FONT><FONT
face="Courier New" size=2><SPAN
style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'"><o:p></o:p></SPAN></FONT></P>
<P class=MsoNormal><FONT face="Courier New" color=red size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: red; FONT-FAMILY: 'Courier New'">
at
mondrian.olap.fun.SetFunDef$ListSetCalc$1.evaluateVoid(</SPAN></FONT><U><FONT
face="Courier New" color=navy size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: navy; FONT-FAMILY: 'Courier New'">SetFunDef.java:132</SPAN></FONT></U><FONT
face="Courier New" color=red size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: red; FONT-FAMILY: 'Courier New'">)</SPAN></FONT><FONT
face="Courier New" size=2><SPAN
style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'"><o:p></o:p></SPAN></FONT></P>
<P class=MsoNormal><FONT face="Courier New" color=red size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: red; FONT-FAMILY: 'Courier New'">
at mondrian.olap.fun.SetFunDef$ListSetCalc.evaluateList(</SPAN></FONT><U><FONT
face="Courier New" color=navy size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: navy; FONT-FAMILY: 'Courier New'">SetFunDef.java:209</SPAN></FONT></U><FONT
face="Courier New" color=red size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: red; FONT-FAMILY: 'Courier New'">)</SPAN></FONT><FONT
face="Courier New" size=2><SPAN
style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'"><o:p></o:p></SPAN></FONT></P>
<P class=MsoNormal><FONT face="Courier New" color=red size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: red; FONT-FAMILY: 'Courier New'">
at mondrian.calc.impl.AbstractListCalc.evaluate(</SPAN></FONT><U><FONT
face="Courier New" color=navy size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: navy; FONT-FAMILY: 'Courier New'">AbstractListCalc.java:67</SPAN></FONT></U><FONT
face="Courier New" color=red size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: red; FONT-FAMILY: 'Courier New'">)</SPAN></FONT><FONT
face="Courier New" size=2><SPAN
style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'"><o:p></o:p></SPAN></FONT></P>
<P class=MsoNormal><FONT face="Courier New" color=red size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: red; FONT-FAMILY: 'Courier New'">
at mondrian.rolap.RolapResult.executeAxis(</SPAN></FONT><U><FONT
face="Courier New" color=navy size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: navy; FONT-FAMILY: 'Courier New'">RolapResult.java:732</SPAN></FONT></U><FONT
face="Courier New" color=red size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: red; FONT-FAMILY: 'Courier New'">)</SPAN></FONT><FONT
face="Courier New" size=2><SPAN
style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'"><o:p></o:p></SPAN></FONT></P>
<P class=MsoNormal><FONT face="Courier New" color=red size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: red; FONT-FAMILY: 'Courier New'">
at mondrian.rolap.RolapResult.evalLoad(</SPAN></FONT><U><FONT
face="Courier New" color=navy size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: navy; FONT-FAMILY: 'Courier New'">RolapResult.java:588</SPAN></FONT></U><FONT
face="Courier New" color=red size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: red; FONT-FAMILY: 'Courier New'">)</SPAN></FONT><FONT
face="Courier New" size=2><SPAN
style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'"><o:p></o:p></SPAN></FONT></P>
<P class=MsoNormal><FONT face="Courier New" color=red size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: red; FONT-FAMILY: 'Courier New'">
at mondrian.rolap.RolapResult.loadMembers(</SPAN></FONT><U><FONT
face="Courier New" color=navy size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: navy; FONT-FAMILY: 'Courier New'">RolapResult.java:563</SPAN></FONT></U><FONT
face="Courier New" color=red size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: red; FONT-FAMILY: 'Courier New'">)</SPAN></FONT><FONT
face="Courier New" size=2><SPAN
style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'"><o:p></o:p></SPAN></FONT></P>
<P class=MsoNormal><FONT face="Courier New" color=red size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: red; FONT-FAMILY: 'Courier New'">
at mondrian.rolap.RolapResult.<init>(</SPAN></FONT><U><FONT
face="Courier New" color=navy size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: navy; FONT-FAMILY: 'Courier New'">RolapResult.java:286</SPAN></FONT></U><FONT
face="Courier New" color=red size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: red; FONT-FAMILY: 'Courier New'">)</SPAN></FONT><FONT
face="Courier New" size=2><SPAN
style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'"><o:p></o:p></SPAN></FONT></P>
<P class=MsoNormal><FONT face="Courier New" color=red size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: red; FONT-FAMILY: 'Courier New'">
at mondrian.rolap.RolapConnection.execute(</SPAN></FONT><U><FONT
face="Courier New" color=navy size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: navy; FONT-FAMILY: 'Courier New'">RolapConnection.java:469</SPAN></FONT></U><FONT
face="Courier New" color=red size=2><SPAN
style="FONT-SIZE: 10pt; COLOR: red; FONT-FAMILY: 'Courier New'">)</SPAN></FONT><FONT
face=Verdana size=2><SPAN
style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"><o:p></o:p></SPAN></FONT></P></DIV></BLOCKQUOTE></BODY></HTML>