Hitachi Vantara Pentaho Community Forums
Results 1 to 2 of 2

Thread: Nested Groups

  1. #1

    Default Nested Groups

    Hi,

    I'm trying to structure an XML document to accept a nested group. I have the first group created, but the nesting process isn't working. I keep receiving this error:

    ERROR: Failed to parse the report definition

    java.lang.IllegalArgumentException: These groups are not comparable, they don't have any subgroup relation

    at com.jrefinery.report.Group.compareTo(Unknown Source)


    That's the short version of the error.


    I guess what would help me is to see a structural example of what a nested grouping in an XML document would look like. If they're being compared, what am I missing from the one to make them not comparable?

    Thank you

  2. #2
    Join Date
    Mar 2003
    Posts
    8,085

    Default

    Hi,

    a subgroup must contain all fields of its parent group.

    Example:

    Group 1 contains the field: "Country".
    A subgroup of this group must also contain the "Country" field, and extends it by one or more fields: "Country", "Town".

    If you want to subgroup this group, you have to include all fields again: "Country", "Town" and extend it by one or more fields "Road", "Name".

    So the group declarations are as follows:
    Code:
    <group name="group1">
       <fields>
         <field>Country</field>
       </fields>
    </group>
    
    <group name="subgroup1">
       <fields>
         <field>Country</field>
         <field>Town</field>
       </fields>
    </group>
    
    <group name="subgroup2">
       <fields>
         <field>Country</field>
         <field>Town</field>
         <field>Road</field>
         <field>Name</field>
       </fields>
    </group>
    Have more fun,
    said Thomas

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 - 2019 Hitachi Vantara Corporation. All Rights Reserved.