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

x
?
Solved

Comparison Chart in Crystal Report

Posted on 2013-06-11
4
Medium Priority
?
1,221 Views
Last Modified: 2016-09-07
I am attempting to chart value changes over time.  I would like to see the numbers of items submitted over a particular time span (generated with a date parameter), grouped by year and by month.  My groups are correct as my counts seem accurate and I get the values that I want in a list form.  I want to visually display this in a chart, however.  Ideally, I want to display the side by side comparison of the months from each year next to each other so that I can see how the last year compared to this year.  My chart keeps giving my all of last year and then a space and then all of this year.  Is there a way that I can do this to achieve a side by side comparison?  A line graph would also be acceptable.  Thank you in advance for any assistance.
0
Comment
Question by:josslmpd
  • 2
4 Comments
 
LVL 101

Accepted Solution

by:
mlmcc earned 2000 total points
ID: 39237925
Create 2 formulas
SubmittedMonth
Month({SubmittedDate})

SubmittedYear
Year({SubmittedDate})

Create the chart using ONCHangeOf
SubmittedMonth then SubmittedYear

mlmcc
0
 

Author Comment

by:josslmpd
ID: 39238121
Thank you.  I thought I needed a new formula, but I wasn't sure what to do with it.
0
 

Expert Comment

by:Karen A
ID: 41788566
I adapted the suggested formulas for my situation and they worked great.   Now, can you suggest a way to create a parameter to choose which "years" you wish to compare?
0
 
LVL 101

Expert Comment

by:mlmcc
ID: 41788945
WHat do you want the user to enter?

A single year and then select data from that year and the previous year?

Selection formula will be

{YourDateField} >= Date({?Year} - 1, 1, 1)
AND
{YourDateField} <= Date(Year,12,31)

You could also select 2 or more years.

mlmcc
0

Featured Post

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone 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

There have always been a lot of questions related to when Crystal Reports evaluates report components (such as formulas, summaries, cross-tabs, charts, to name a few examples). Crystal Reports uses a two-pass reporting process to provide greater …
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…
Loops Section Overview
When cloud platforms entered the scene, users and companies jumped on board to take advantage of the many benefits, like the ability to work and connect with company information from various locations. What many didn't foresee was the increased risk…

824 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