Seal Report Forum
»
Report Edition
»
Reports
»
Bar chart month vs month last year?
Rank: Newbie
Groups: Registered
Joined: 9/24/2020(UTC) Posts: 2 Thanks: 1 times
|
How can i create a bar chart to compare an amount of the current years month to the last years month. The bars schould be side by side like this: Code:
|
800 |
|
700 | x o o
| o x o x o x o x x o x o
600 | x o x o x o x o x o x o x o x o
| x o x o x o x x o x o x o x o x o x o x o x
500 | x o x o x o x o x o x o x o x o x o x o x o x o
| x o x o x o x o x o x o x o x o x o x o x o x o
400 | x o x o x o x o x o x o x o x o x o x o x o x o
| x o x o x o x o x o x o x o x o x o x o x o x o
300 | x o x o x o x o x o x o x o x o x o x o x o x o
| x o x o x o x o x o x o x o x o x o x o x o x o
200 | x o x o x o x o x o x o x o x o x o x o x o x o
| x o x o x o x o x o x o x o x o x o x o x o x o
100 | x o x o x o x o x o x o x o x o x o x o x o x o
------------------------------------------------------------------------------
J F M A M J J A S O N D
x =2020 o =2019
Edited by user Thursday, September 24, 2020 1:12:10 PM(UTC)
| Reason: Not specified
|
|
|
|
Rank: Administration
Groups: Administrators
Joined: 12/20/2013(UTC) Posts: 1,209 Thanks: 14 times Was thanked: 206 time(s) in 199 post(s)
|
To do that: * Create a model having 'Order Date' in Row, 'Order Year' in Column, 'Amount' in Data * Set a restriction to limit the order years * Change the SQL of 'Order Date' using the custom SQL property to get only the month: month(Orders.OrderDate) for SQLServer or MS Access Then change the Data Type to numeric * Configure the serie: 'Order Date' is Axis, 'Order Year' is a Splitter, 'Amount' is a bar chartJS In 'Amount' set Sort Type to 'By Axis Label' Then it should work. If you want the month with their name, you have to create manually a small enumerated list for Months having the property 'Used defined position to sort in reports' to true, then assign it to 'Order Month' in the Custom Enum property. I have attached the sample for Northwind SQLServer... 16-Sales comparison per month.srex (6kb) downloaded 2 time(s).Edited by user Friday, September 25, 2020 7:37:13 AM(UTC)
| Reason: Not specified
|
1 user thanked epf for this useful post.
|
|
|
Rank: Newbie
Groups: Registered
Joined: 9/24/2020(UTC) Posts: 2 Thanks: 1 times
|
Thank you for the excellent description. That works!
|
|
|
|
Seal Report Forum
»
Report Edition
»
Reports
»
Bar chart month vs month last year?
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.