Skip to Content

How to create a bar diagram that compares the actuel values against min and max group values?

I hope I can explain my target. :-)

I have a list of costs with: businsspartner, value and date (not only the year)

Now I want to create a bar diagram per businesspartner that shows my the sum of all values per year.

Thats the easy part...

But now I want two additional bars per year that shows me min(sum(value)) and max(sum(value)) over all businesspartners in the according year.

So my goal is to have a diagram per businesspartner where I can see the year on the x-axis and the amount on the y-axis:

2018: current businespartner: 25000, the businesspartner with the smalles amount has 2500 and the businesspartner with the largest amount has 250000.

2019: current businespartner: 30000, the businesspartner with the smalles amount has 10000 and the businesspartner with the largest amount has 70000
So I want to have thee bars per year with the amount if the current, and min and max with the highest and lowest amounts.

Single records are like this but with multiple values per month

BP1	01.01.2018	300
BP1	01.02.2018	1000
BP1	01.03.2018	1500
BP1	01.04.2018	500
BP1	01.05.2018	4000
BP1	01.06.2018	1500
BP1	01.07.2018	5500
BP1	01.08.2018	3000
BP1	01.09.2018	1000
BP1	01.10.2018	200
BP1	01.11.2018	5000
BP1	01.12.2018	1500
BP2	01.01.2018	30
BP2	01.02.2018	100
BP2	01.03.2018	150
BP2	01.04.2018	50
BP2	01.05.2018	400
BP2	01.06.2018	150
BP2	01.07.2018	550
BP2	01.08.2018	300
BP2	01.09.2018	100
BP2	01.10.2018	20
BP2	01.11.2018	500
BP2	01.12.2018	150
BP3	01.01.2018	3000
BP3	01.02.2018	10000
BP3	01.03.2018	15000
BP3	01.04.2018	5000
BP3	01.05.2018	40000
BP3	01.06.2018	15000
BP3	01.07.2018	55000
BP3	01.08.2018	30000
BP3	01.09.2018	10000
BP3	01.10.2018	2000
BP3	01.11.2018	50000
BP3	01.12.2018	15000

According to the above list I would expect for BP1 in 2018 a value of 25000 compared to 2500 (min) and 250000 (max).

If I create a formula year(date) in cr an create a diagram with this forumla and sum, min and max totals I get the correct sum but min and max are the values of the singlerecords and not the min/max-values of the sum per businesspartner.

So in the example above I get 25000 for BP1 but 20 as min and 55000 as max. :-/

Has anyone an idea how to achieve this in crystal reports?

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

0 Answers

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.