Report Design
 Crystal Reports Forum : Crystal Reports 9 through 2020 : Report Design
Message Icon Topic: Sum of Running total(s) Post Reply Post New Topic
Page  of 3 Next >>
Author Message
nabilino
Newbie
Newbie
Avatar

Joined: 02 Nov 2009
Location: United States
Online Status: Offline
Posts: 25
Quote nabilino Replybullet Topic: Sum of Running total(s)
    Posted: 12 Nov 2009 at 1:14pm
Hi everyone,
 
I have running totals summing deduction codes by month. I want to sum up all the months for a yearly total and display it on the same detail line.
for ex.
 
Jan.   Feb.    ...     YTD
$10    $5      ...     $15
 
I tried doing that using another running total but it doesnt sum on other running totals. The only way I think is to do a formula and display it, but I don't know how to write the formula.
 
I tried Sum({#January}{#February}...) but it didn't work
I also tried {#Jan} + {#Feb} +... but it displays blanks
 
Any ideas?
 
Thank you
IP IP Logged
Grifter
Newbie
Newbie


Joined: 02 Jun 2009
Online Status: Offline
Posts: 32
Quote Grifter Replybullet Posted: 13 Nov 2009 at 6:15am
I think you need to go into formula editor in the field explorer window. Right click formula editor and create new calculation. Once your in the formula editor you can select Formul, Selection and Formatting from the left window. From their I think you can make up some sort of calculation or sum, haven't ever done one myself though.


G
IP IP Logged
nabilino
Newbie
Newbie
Avatar

Joined: 02 Nov 2009
Location: United States
Online Status: Offline
Posts: 25
Quote nabilino Replybullet Posted: 13 Nov 2009 at 7:29am
I tried that but it won't let me select my running totals fields which I want to sum and display for YTD total.
IP IP Logged
DBlank
Moderator
Moderator


Joined: 19 Dec 2008
Online Status: Offline
Posts: 9053
Quote DBlank Replybullet Posted: 13 Nov 2009 at 8:44am
Originally posted by nabilino

Hi everyone,
 I also tried {#Jan} + {#Feb} +... but it displays blanks
 
 
Did you palce this anywhere but the report footer?
If so it likely would by all blank. Running Totals only work when placed below the data that it is calculating, in this case all rows therefore on the report footer.
IP IP Logged
nabilino
Newbie
Newbie
Avatar

Joined: 02 Nov 2009
Location: United States
Online Status: Offline
Posts: 25
Quote nabilino Replybullet Posted: 13 Nov 2009 at 8:51am
No, I didn't place the running totals below the data it's calculating. I have running totals calculating Ded Code amounts by month and displaying it on the same detail row. .... it seems to be working ok
I wanted to add the YTD total to sum all running totals and display it along with the month totals.
IP IP Logged
DBlank
Moderator
Moderator


Joined: 19 Dec 2008
Online Status: Offline
Posts: 9053
Quote DBlank Replybullet Posted: 13 Nov 2009 at 9:07am
Sorry, I should have been clearer.
For a RT you can place it on or below the level of the calcualtion so your other ones work becasue they are displaying the data as you wish. However if you are now trying to show the data as an aggregate it won't work.
If you do not have any duplicte data then you really just want a SUM of all the rows correct?
SUM(field) and place it wherever you want on the report.
If you use INsert Summary, these are calculated before displaying and can be palced anywhere on the report (unlike a RT).
IP IP Logged
nabilino
Newbie
Newbie
Avatar

Joined: 02 Nov 2009
Location: United States
Online Status: Offline
Posts: 25
Quote nabilino Replybullet Posted: 13 Nov 2009 at 9:32am
So you're saying that I can't Sum the running totals already in the row calculating the amount of ded codes and display it in the same row?
If I want to display the total of the row it has to be below it?
I'm just concerned about the output in csv form and that it would be ugly for users to understand.
IP IP Logged
DBlank
Moderator
Moderator


Joined: 19 Dec 2008
Online Status: Offline
Posts: 9053
Quote DBlank Replybullet Posted: 13 Nov 2009 at 9:45am
For clarity sake you cannot SUM a RT at all (e.g. SUM(#RT) )
and you cannot add the values of a RT and display anywhere prior to all of the fields that are included in the calcualtion haev all ready been displayed in the report.
Example
Row 1=January
Row 2 = Feb
row 3 = March
etc.
A RT field or formula fieldin adding all of the months RTs togther cannot be displayed on each row because data  it needs to include has not been read into the RTs yet.
Make sense?
 
 


Edited by DBlank - 13 Nov 2009 at 9:46am
IP IP Logged
nabilino
Newbie
Newbie
Avatar

Joined: 02 Nov 2009
Location: United States
Online Status: Offline
Posts: 25
Quote nabilino Replybullet Posted: 13 Nov 2009 at 9:53am

Ok, so there is no way of having the following in the report:

Row1: {#Jan} {#Feb} {#March}...{#YTD}
Row2: {#Jan} {#Feb} {#March}...{#YTD}
 
What I have to do is:
 
Row1:      {#Jan} {#Feb} {#March}...
GrpFooter:                                            {#YTD}  
Row2:       {#Jan} {#Feb} {#March}...
GrpFooter:                                            {#YTD}  
 
Is that what you're saying? Thanks
 
IP IP Logged
DBlank
Moderator
Moderator


Joined: 19 Dec 2008
Online Status: Offline
Posts: 9053
Quote DBlank Replybullet Posted: 13 Nov 2009 at 10:04am

Lets get back to basics here.

What data do you have and how do you want it to appear?
IP IP Logged
Page  of 3 Next >>
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.