[Bug] Charts with data grouping

Stimulsoft Reports.NET discussion
Post Reply
seckarp
Posts: 2
Joined: Thu Aug 25, 2016 7:52 am

[Bug] Charts with data grouping

Post by seckarp »

Hello,

just as a background info, I'm currently looking for an alternate reporting tool to Crystal Reports that our company's been using for years now. I've tried Telerik but was not completely satisfied. Then I stumbled upon Stimulsoft Reports, installed the trial and I'm enjoying working with the software so far. But recently I've discovered an obstacle that I need to resolve in order to move on.

Now to the problem. I have data in my report that describe usage of certain machines over time. Basically, I have a table with machines and for each there are dates with corresponding usage values. I can easily visualize this in a line chart where there is the time as an argument (x axis), the usage as values (y axis) and machines as auto series key data column (to generate series). That works fine, the particular series in the chart represent the usage of the machines over time.

The problem comes when the machines are divided into several groups (in the table there is a column describing the group assigned to each machine). I will need to make a chart separately for the machines in each group. It's easy to do with just a table - I've created a group band with a condition set to the machine group column. This way I'll add text fields into a data band inside the group band and generate data for each machine group the way I want. But if I add the chart into the group header, the chart works with all of the data and not only with the grouped as one would expect.

This would work in Crystal Reports for example. In Telerik I had the same problem, but I managed to resolve it by binding the data source of the chart to the data of the object it was inside (the group header). But how to do this in Stimulsoft Reports? This is key for me because we need to generate multiple charts based on data grouping in our reports.

Thank you in advance for any insight into this.

EDIT: The bug is described in the post below.
Last edited by seckarp on Fri Aug 26, 2016 7:06 am, edited 1 time in total.
HighAley
Posts: 8430
Joined: Wed Jun 08, 2011 7:40 am
Location: Stimulsoft Office

Re: Charts with data grouping

Post by HighAley »

Hello.

We are very glad that you have chose our product.
At first I should say that it's possible to use several data band on one page. And it's possible to create the same reports different ways.

If you need to show the chart on a group header, you could add a variable, set the value of the current group and then use in in the chart's filter.

The other way is to create master-detailed report and set the Relation and Master Component for the chart.

You could see the both solutions at the attached report template.
ChartGroup.mrt
(44.62 KiB) Downloaded 323 times
We suggest you to read the The main differences of reporting features between Crystal Reports and Stimulsoft Reports article.

Thank you.
seckarp
Posts: 2
Joined: Thu Aug 25, 2016 7:52 am

Re: Charts with data grouping

Post by seckarp »

Thank you for the quick answer. I've applied the fisrt solution you mentioned to my problem and got it resolved - the chart only displays data in the current group.

It is, however, rather clumsy way to solve this. Besides, it comes with some side effects. For example, the legend of the chart displays all of the other elements insted only those in the current group. Anyway, I managed to resolve that by selecting Hide Series with Empty Title in the legend properties.

Also, if I try to add another series to the graph (e.g. in addition of machine usage I also want to display its production) it doesn't work out. Due to this I thought that chart filters only applies on the series I set them to. Hence I set the filter again for the new series the same way I set it for the first series. Then when I tried to preview the report an exception popped out:
Problem when parsing Chart Argument = chartData.Group == CurrentGroup value
When I looked back at the chart filters, I've discovered there's a bug. Just by selecting different series and going to the filter setting, the filters duplicated itself (see below).

Image

The exception is probably connected to the bug. Is there any workaround that I could use to add another chart series to my graph but at the same time use the grouped data? Would it work with the second solution you provided (using master-detailed report)?
Alex K.
Posts: 6488
Joined: Thu Jul 29, 2010 2:37 am

Re: [Bug] Charts with data grouping

Post by Alex K. »

Hello,

Can you please send us a simple report with test data which reproduces the issue for analysis. We will try to find a solution for you.

Thank you.
HighAley
Posts: 8430
Joined: Wed Jun 08, 2011 7:40 am
Location: Stimulsoft Office

Re: [Bug] Charts with data grouping

Post by HighAley »

Hello.

Sorry, there were some changes in the Chart editor.
We have reproduced the bug.
We will try to fix it shortly and let you know about results.

Thank you.
HighAley
Posts: 8430
Joined: Wed Jun 08, 2011 7:40 am
Location: Stimulsoft Office

Re: [Bug] Charts with data grouping

Post by HighAley »

Hello.

We have made an improvement.
Please, check our next build when it will be available.

Thank you.
Post Reply