Discussions
Categories
Groups
Community Home
Categories
INTERNAL ENABLEMENT
POPULAR
PUBLIC CLOUD
PRIVATE CLOUD
Quick Links
MY LINKS
HELPFUL TIPS
Back to website
Home
Intelligence (Analytics)
Gantt Chart Task Labels Not Showing on Multi-Series
bmweiler09
<p>Hello all,</p><p> </p><p>I am trying to make a 2 series Gantt Chart on BIRT using an SQL Query that returns these columns:</p><p> </p><p>Start Time Duration Process Name Location Name</p><p> </p><p> 19.823 67.324 Process 1 Location 1</p><p> 22.567 97.367 Process 1 Location 2</p><p> 36.567 53.367 Process 2 Location 2</p><p> 38.567 47.367 Process 2 Location 1</p><p> </p><p>The start time and duration is in unit days, and I add them to the process start time using BIRT's addDay function. I am attempting to have 2 series on the same chart grouping by location, and the problem is when I do this the task labels for series 1 never show on the chart. I have tried adding the Location Name to the Optional Y Series Grouping feature in the Select Data section, I have also tried creating 2 series manually by applying</p><p>if (row["LOCATION_NAME"] == params["Location1"].value) </p><p>to all the fields in the Value (Y) Series for series 1 and a "Location2" if statement for series 2. On the formatting, I have the x-axis and series labels turned off, and the task labels turned on and positioned to the left. the silly thing is, if I position the task labels for both series to the right they both show up on the graph.</p><p> </p><p>Thank you for any assistance you can provide.</p><p> </p>
Find more posts tagged with
Comments
mwilliams
<p>What is your BIRT version?</p>
bmweiler09
<p>3.7.2</p>
mwilliams
<p>I'm not sure I'm understanding how exactly your chart is set up. Can you add a chart to this report set up like yours? I have already included your data in a scripted dataset. Thanks!</p>
bmweiler09
<p>mwilliams,</p><p> </p><p>I've set up the chart exactly how mine is and reattached it. As you can see on the preview, the task labels for Location 1 do not show up on the chart. I also added a img of my chart preview incase it shows up differently for you. Let me know if you're able to figure this out. Thank you</p><p> </p><p>
mwilliams
<p>It would appear that the empty task labels from series2 are covering up the ones from series1. If you were to change your start and end time expressions to be like:</p><p> </p><p></p><pre class="_prettyXprint _linenums:0">if(row["Location Name"] == 'Location 1'){BirtDateTime.addDay(params["StartDate"].value, (row["Start Time"]+row["Duration"]))}else{params["StartDate"].value}</pre><p> </p><p>the labels show up, but so do slivers of bars for the extra series created. You could probably get rid of these pretty easy. That'll be one solution to get around the issue.</p>