Report Design
 Crystal Reports Forum : Crystal Reports 9 through 2022 : Report Design
Message Icon Topic: several unique selections Post Reply Post New Topic
Author Message
LTLhawk
Newbie
Newbie


Joined: 11 Sep 2007
Online Status: Offline
Posts: 2
Quote LTLhawk Replybullet Topic: several unique selections
    Posted: 04 Oct 2007 at 4:41pm
Hello All,
 
I am new to CR and I have a basic question. In my report I want to have several different selections for data but I am not sure how to do this. I have in my report selection 3 criteria for the entire report. Now I want to break that down into other criteria. I used the group dialog to create a gouple groups, but I can only set up selection criteria for 1 group and it effects all the groups. I need to have seperate criteria selection for several different groups. Example:
 
top level = all names
 
group 1 = I want to have count (number of names = Ben)
group 2 = I want to have count (number of names = Jerry)
group 3 = Select criteria  from a different table in the database (list flavors)
 
Again, I know this is basic, but I have been stuck for several days and have to ask for help. Thanks for any advice.
IP IP Logged
BrianBischof
Admin Group
Admin Group
Avatar

Joined: 09 Nov 2006
Online Status: Offline
Posts: 2458
Quote BrianBischof Replybullet Posted: 04 Oct 2007 at 10:40pm
I'm not sure about how you want to print the detail records. For the top level you say that you want to print all records, but does this imply that you want to print some of those same names in the following groups as well? Or are you just looking to print the subtotals for records that meet that criteria?

If you want to print the records (again) in the groups, then you need to create subreports for each group. You can't print the same record twice in the same report.

If you want to just keep track of the subtotals, then you can create a manual running formula which has three global variables and increment the appropriate formula depending upon the current record. Here is a bit of pseudo-code:
Global NumberVar G1;
Global NumberVar G2;

If {table. g1Field}= 1 AND {table.Name}="Ben" Then
    G1 := G1 + 1;

If {table. g2Field}= 1 AND {table.Name}="Jerry" Then
    G2 := G2 + 1;


Does that help at all?
Please support the forum! Tell others by linking to it on your blog or website:<a href="http://www.crystalreportsbook.com/forum/">Crystal Reports Forum</a>
IP IP Logged
LTLhawk
Newbie
Newbie


Joined: 11 Sep 2007
Online Status: Offline
Posts: 2
Quote LTLhawk Replybullet Posted: 05 Oct 2007 at 7:54am
I think that will do it.. Thanks Brian.
IP IP Logged
Post Reply Post New Topic
Printable version Printable version

Forum Jump
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot delete your posts in this forum
You cannot edit your posts in this forum
You cannot create polls in this forum
You cannot vote in polls in this forum



This page was generated in 0.016 seconds.