Print Page | Close Window

Group hierarchy level

Printed From: Crystal Reports Book
Category: Crystal Reports for Visual Studio 2005 and Newer
Forum Name: Report Design
Forum Discription: The best way to design a report and problems you have encountered
URL: http://www.crystalreportsbook.com/forum/forum_posts.asp?TID=12523
Printed Date: 29 Apr 2024 at 7:28am


Topic: Group hierarchy level
Posted By: vadim
Subject: Group hierarchy level
Date Posted: 07 Mar 2011 at 4:24am
I have some problem with "group name fields"
 
At the moment I can do only this structure grouping:
 
Year
     Object Type 
          Object Name
 
i.e. each group included into another, therefore I can do only grouping
Year -> Object Type -> Object Name
 
but I need last 2 groups independent one from other, i.e. same level:
 
Main group
     Object Type
     Object Name
 
for making 2 types grouping:
 
Year -> Object Type
Year -> Object Name
 
at the moment I need to include sub-report with necessary group. But it's not normal.
 
please, any offers?Cry



Replies:
Posted By: lockwelle
Date Posted: 08 Mar 2011 at 3:33am
Since all reporting tools display groups as a/b/c, not a/b a/c the subreport is one way to go, and rather logical. 
 
I was going to say to create a formula that would display both b/c, but it won't work, as what CR really needs is 2x the data for what you want to happen...it only reads a data row once, but you are looking to have it read twice (the subreport accomplishes this for you)
 
If you are using a stored proc, you could create a column in the return set for the grouping value and then fill it in using selects (you would have 2x the amount of data as the original dataset, which may or may not work the aggregate functions in the report)
 
Depending on how the report is formatted, it might be easier to stay with the subreport.  While I try not to use them, as they result in slower reports and more hits the database (unless you pushing the data to the report), they do have their place.
 
HTH



Print Page | Close Window