Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

Evaluate Group Summaries against each other in Crystal Reports

Posted on 2013-05-16
2
Medium Priority
?
302 Views
Last Modified: 2013-05-16
I have a report with summaries on a group.  I cannot figure out how I can evaluate the group summaries against each other.  Specifically, I have two values in each row, 'dollar amount' and 'year'.  In my group header/footer I have a sum total of 'dollar amount' grouped under each 'year'.  So I can have a total for 2012 and a total for 2013.  I can even do a grand total for 2012 and 2013 together, but how do I create a calculation where I get the difference of 2013 minus 2012?
0
Comment
Question by:Jake Pratt
2 Comments
 
LVL 101

Accepted Solution

by:
mlmcc earned 2000 total points
ID: 39172384
I can think of 2 methods.

1.  Use variables to save the summary values then calculate the difference.

2.  Create 2 formulas
LastYear
If Year({DateFIeld}) = Year(Currentdate) - 1 then
    {AmountField}

ThisYear
If Year({DateFIeld}) = Year(CurrentDate) then
   {AmountField}

Those formulas can be summarized anywhere to get the totals for LastYar and ThisYear and then a difference can be calculated

Sum({@ThisYear}) - Sum({@LastYear})

mlmcc
0
 

Author Closing Comment

by:Jake Pratt
ID: 39172592
Now why didn't I think of that?!  Very nice.  Thanks.
0

Featured Post

Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Crystal Reports: 5 Tests for Top Performance It is complete, your masterpiece report.  Not only does it meet your customer’s expectations, it blows them out the water, all they want is beautifully summarised and displayed in a myriad of ways. …
Hello everyone, Hope you find this as helpful as we did. We have on the company I work for an application built in Delphi V with Crystal Reports 8. We all know that Crystal & Delphi can be temperamental sometimes and the worst thing is, nearly…
This Micro Tutorial will teach you how to add a cinematic look to any film or video out there. There are very few simple steps that you will follow to do so. This will be demonstrated using Adobe Premiere Pro CS6.
Despite its rising prevalence in the business world, "the cloud" is still misunderstood. Some companies still believe common misconceptions about lack of security in cloud solutions and many misuses of cloud storage options still occur every day. …

926 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question