Plotting multiple Lines in a Line Chart

Hi

I have to draw a chart that displays the month wise marketshare of various service providers.
The DB has a table which stores month , service provider and marketshare. I am using a line chart to display months on X axis and Marketshare on Y axis. I am able to draw a seperate Line graph for each service provider using IReports but I need help to draw one line chart for all service providers

Please see the attachmnet for the exampple chart that is to be drwan.

Thanks in advance [file name=Chart_sample.doc size=49152]

Attachments: 
anujapuri's picture
Joined: Apr 7 2008 - 5:59pm
Last seen: 14 years 4 months ago

6 Answers:

Hi,

each "line" needs its own "Category Series" (in Chart Properties - Chart Data - Details)

regards,

Kai Schmitte
kschmitte's picture
259
Joined: Sep 27 2006 - 1:20am
Last seen: 15 years 10 months ago
Hi

Thanks for your Help.

I have tried creating Category series for each service provider but I need help to define the Value Expression for each Category series . I need where clause in the value expression for each caregory series for examle correspondg to serviceoperator xyz , the value expression for category series corresponding to opeartor xyz should be saying 'plot marketshare for this record from DB if serviceoperator="xyz" '

Please tell me how to define this value expression. Thanks for your help
anujapuri's picture
Joined: Apr 7 2008 - 5:59pm
Last seen: 14 years 4 months ago
This is a completly different issue ;)

I would create a subreport with a query designed to return exactly the data I need in the chart - and then just put in the resluting fields. If needed you can pass parameters to your subreport (like your "YXZ").

Kai
kschmitte's picture
259
Joined: Sep 27 2006 - 1:20am
Last seen: 15 years 10 months ago
Hi

Thanks for your help. I will try exploring sub reorts as, Jasper and iReports are new to me .

Thanks , I appreciate the timely replies.
anujapuri's picture
Joined: Apr 7 2008 - 5:59pm
Last seen: 14 years 4 months ago
hi anujapuri there. i cant display multiple lines or series in the same chart. i saw your chart image (and it makes just what i need) and i want to know if you can please make your .jrxml public o send it to my email valentina.trujillo@gmail.com


thanks! :blink:
t3en4's picture
48
Joined: May 16 2008 - 1:42am
Last seen: 14 years 2 months ago
Hi anujapuri/t3en4 I have the same requirement and a similar table. Got any Ideas or solutions. Can you help me out
kantheti.prajyodh's picture
Joined: Nov 18 2016 - 1:15am
Last seen: 5 years 1 month ago
Feedback