[Mondrian] ParentChild hierarchy in Mondrian 3.2

Anton Nikitin cybernelly at gmail.com
Wed Jun 30 08:49:23 EDT 2010


I am experiencing some difficulties after upgrading from 3.1.2 to 3.2.0 
with parent-child hierarchy.

I have a hierarchy defined as follows:

<Dimension name="Liquidity Risk Group">
<Hierarchy hasAll="true" allMemberName="All Nodes" primaryKey="NODEID">
<Table name="LIQUIDITYRISKGROUP"/>

<Level approxRowCount="100" name="Risk Group" column="NODEID" 
nameColumn="RISKGROUPNAME"
                 parentColumn="PARENT" nullParentValue="-1" 
type="Numeric" uniqueMembers="true"
                 levelType="Regular" hideMemberIf="Never">
<Closure parentColumn="ANCESTORID" childColumn="NODEID">
<Table name="RISKGROUPCLOSURE" />
</Closure>
</Level>
</Hierarchy>
</Dimension>

And with such definition it returns empty cells if MDX includes any 
member from this hierarchy other than AllMember.
If I comment out closure definition it starts to work correctly.

During analysis I found the following in Mondrian log:


[2010-06-30 16:26:51,896] [DEBUG] (RolapUtil             ) Segment.load: 
executing sql [select "RISKGROUPCLOSURE"."ANCESTORID" as "c0", 
sum("DAILYCFBYRISKGROUPHIERARCHY"."STRESSCFAMOUNTPLUS"+"DAILYCFBYRISKGROUPHIERARCHY"."STRESSCFAMOUNTMINUS") 
as "m0" from "
RISKGROUPCLOSURE" "RISKGROUPCLOSURE", "DAILYCFBYRISKGROUPHIERARCHY" 
"DAILYCFBYRISKGROUPHIERARCHY" where 
"DAILYCFBYRISKGROUPHIERARCHY"."NODEID" = "RISKGROUPCLOSURE"."NODEID" and 
"RISKGROUPCLOSURE"."ANCESTORID" = 1000.0 group by 
"RISKGROUPCLOSURE"."ANCESTORID"], exec 15 ms

[2010-06-30 16:26:51,896] [DEBUG] [/lrm230] [OTIDO\aln at 192.168.1.171] - 
(RolapUtil             ) Segment.load: done executing sql [select 
"RISKGROUPCLOSURE"."ANCESTORID" as "c0", 
sum("DAILYCFBYRISKGROUPHIERARCHY"."STRESSCFAMOUNTPLUS"+"DAILYCFBYRISKGROUPHIERARCHY"."STRESSCFAMOUNTMINUS") 
as "m0" from "RISKGROUPCLOSURE" "RISKGROUPCLOSURE", 
"DAILYCFBYRISKGROUPHIERARCHY" "DAILYCFBYRISKGROUPHIERARCHY" where 
"DAILYCFBYRISKGROUPHIERARCHY"."NODEID" = "RISKGROUPCLOSURE"."NODEID" and 
"RISKGROUPCLOSURE"."ANCESTORID" = 1000.0 group by 
"RISKGROUPCLOSURE"."ANCESTORID"], *exec+fetch 15 ms, 0 rows*

[2010-06-30 16:26:51,896] [DEBUG] [/lrm230] [OTIDO\aln at 192.168.1.171] - 
(FastBatchingCellReader$Batch) Batch.loadAggregation (millis) 15
[2010-06-30 16:26:51,896] [DEBUG] [/lrm230] [OTIDO\aln at 192.168.1.171] - 
(FastBatchingCellReader) loadAggregation (millis): 15
[2010-06-30 16:26:51,897] [DEBUG] [/lrm230] [OTIDO\aln at 192.168.1.171] - 
(ResultBase            ) RolapResult<init>: FREE_MEMORY: 197383kb 63.82%
[2010-06-30 16:26:51,897] [DEBUG] [/lrm230] [OTIDO\aln at 192.168.1.171] - 
(mdx                   ) 1: exec: 18 ms

It reports that query returned 0 rows (if I understand it correctly).
But when I tried to execute the same SQL manually against my database it 
returned one row.

Could anybody help me with it? We didn't change schema definition and 
database content, so it worked in 3.1.2.
Any hint why closure could stop working would be much appreciated...

Thanks.

Anton Nikitin
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.pentaho.org/pipermail/mondrian/attachments/20100630/288ca5d4/attachment.html 


More information about the Mondrian mailing list