Hitachi Vantara Pentaho Community Forums
Results 1 to 3 of 3

Thread: wrong unique name for default member when hasAll=false

  1. #1
    Join Date
    Jan 2007

    Default wrong unique name for default member when hasAll=false

    I have run into a situation where Mondrian (2.2.2) returns a wrong unique name for the default member. It seems to happen when the following conditions are met:
    • hasAll="false"
    • nameColumn specified
    Consider for example the following schema:
    <Schema name="Bug001">
      <Cube name="Employees">
        <Table name="empl"/>
        <Dimension name="Department" foreignKey="dept">
          <Hierarchy hasAll="false" primaryKey="d_id" primaryKeyTable="dept">
            <Join leftKey="comp" rightKey="c_id">
              <Table name="dept"/>
              <Table name="comp"/>
            <Level name="Company" uniqueMembers="true"
                   table="comp" column="c_id" nameColumn="c_name"
            <Level name="Department" uniqueMembers="true"
                   table="dept" column="d_id" nameColumn="d_name"
        <Measure name="Salary" column="salary" aggregator="sum" formatString="#,#"/>
    Here the "Department" hierarchy has a company as its default member. The unique name I get has the form [Department].[c_id] instead of the expected [Department].[c_name]. In other words, the unqiue name is not honoring the nameColumn attribute.

    I am enclosing a JSP page (in a zip archive) that describes how to reproduce the problem. Just run that page (bug-001.jsp) from the Mondrian sample application and follow the instructions..

    Suggestions on how to work around the problem are most welcome. I really don't want hasAll because of the extra header in the JPivot table. Thanks.

    -- Patrick
    Attached Files Attached Files

  2. #2
    Join Date
    Jan 2007


    This problem is reproducible with Mondrian 2.4.2 (using a modified version of the test JSP). It appears to have been fixed in 3.0.3.

  3. #3
    Join Date
    Nov 1999


    If it's fixed in 3.0.3, that's great. I am going to add a test case (method SchemaTest.testDefaultMemberName) to make sure this stays fixed. Will be checked in in a few days.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
Privacy Policy | Legal Notices | Safe Harbor Privacy Policy

Copyright © 2005 - 2017 Pentaho Corporation. All Rights Reserved.