Report Design
 Crystal Reports Forum : Crystal Reports 9 through 2020 : Report Design
Message Icon Topic: averages at the group level based on report total Post Reply Post New Topic
<< Prev Page  of 2
Author Message
nbritton
Newbie
Newbie
Avatar

Joined: 30 Sep 2009
Online Status: Offline
Posts: 25
Quote nbritton Replybullet Posted: 16 May 2011 at 6:29am
I have tried that with the jobid, the problem i ran into was it added the job numbers togther and then devided by the count.  Giving me an average that mactched the job number.  Thats why i have been trying to use a set of running totals.  One for the group and another for the report total.
IP IP Logged
DBlank
Moderator
Moderator


Joined: 19 Dec 2008
Online Status: Offline
Posts: 9053
Quote DBlank Replybullet Posted: 16 May 2011 at 6:33am
you can change the level at which is shows the percentage by changing the group level in the percentage option section of teh summary.
Am I missing something else there?
IP IP Logged
nbritton
Newbie
Newbie
Avatar

Joined: 30 Sep 2009
Online Status: Offline
Posts: 25
Quote nbritton Replybullet Posted: 16 May 2011 at 7:02am
All i have there is a grand total of job id.  IT appears to be adding the job ids together to get the total.
IP IP Logged
DBlank
Moderator
Moderator


Joined: 19 Dec 2008
Online Status: Offline
Posts: 9053
Quote DBlank Replybullet Posted: 16 May 2011 at 7:06am
try adding another insert summary as...
 
field to summarize = your PK field
type = distinct count
location = gf1 this should be your count of all jobs per customer
 
now use this as your level to get the percentages per job
This gf1 summary field can be suppressed
IP IP Logged
nbritton
Newbie
Newbie
Avatar

Joined: 30 Sep 2009
Online Status: Offline
Posts: 25
Quote nbritton Replybullet Posted: 16 May 2011 at 7:40am
I dont think that will work.  There are multiple instances of the same job as it will retry in the autoscheduler.  To do so i would need to find away to use the masterserver, jobid, instance combined to accomplish that.   I dont think that would give me what i am fully looking for.
IP IP Logged
DBlank
Moderator
Moderator


Joined: 19 Dec 2008
Online Status: Offline
Posts: 9053
Quote DBlank Replybullet Posted: 16 May 2011 at 7:41am
Disticntcount at teh group level should
IP IP Logged
DBlank
Moderator
Moderator


Joined: 19 Dec 2008
Online Status: Offline
Posts: 9053
Quote DBlank Replybullet Posted: 16 May 2011 at 8:03am

I was trying to give you a way to avoid sub reports.

If you can garner your numbers via an insert summary function (however you figure it out) these can be used as values BEFORE the last record in calculation is printed. If you cannot do this then you would have to use sub reports to get your value for the percentage.
You can create the subreport in the section before the value is needed (e.g. a GH1a) then pass the values from the subreport back to the main report via a shared variable. This has to be after the subreport is run (e.g GH1b). Then that value (in the shared variable)can be used in any calculation formula in the main report you want anywhere 'below' GH1b.
IP IP Logged
nbritton
Newbie
Newbie
Avatar

Joined: 30 Sep 2009
Online Status: Offline
Posts: 25
Quote nbritton Replybullet Posted: 16 May 2011 at 8:13am
I apprciate the assitacnce DBlank.  I am working to attempt the idea on the job instance but i am not sure its working.  I am going to play with a few options there, but it seems to not update the total count correctly.  It still appears to be adding up the sum of the job ids and then averaging that. 
 
Are you aware of any other way i may be able to precent the data.  I have thought about cross-tab but i am not sure if it would work either in the way i am needing.
 
I thought this would be a pretty striaght approch or simple thing to do.  Bottom line all i need is the group average of the overall record count.  I want to know what average of the failures reported by that that jobid are in relation to the overall count from all jobs.
IP IP Logged
DBlank
Moderator
Moderator


Joined: 19 Dec 2008
Online Status: Offline
Posts: 9053
Quote DBlank Replybullet Posted: 16 May 2011 at 8:21am

Hmm.

Make a formula to do the percentage for you.
DistinctCount ({table.pk}, {table.jobtitle}) % DistinctCount ({table.pk}, {table.client})
 
 
IP IP Logged
DBlank
Moderator
Moderator


Joined: 19 Dec 2008
Online Status: Offline
Posts: 9053
Quote DBlank Replybullet Posted: 16 May 2011 at 8:21am
the formula should work because it is using the summary values of the distinctcount of PK @ both Group 1 and Group 2

Edited by DBlank - 16 May 2011 at 8:22am
IP IP Logged
<< Prev Page  of 2
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.018 seconds.