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)
Added multiple values on a report
DavidGress
I'm using Birt 11SP3.
I've written part of a report that gets 3 sums from 3 different data sets. Is there a way to sum those values and place that on the report?
Sum1 + Sum2 + sum3 = Total.
SumN are in Data Controls within a Grid control.
Find more posts tagged with
Comments
kclark
You can create aggregate each field and then set them all in a global persistent variable that you can pull from later. Doing something like this from the onRender() of the aggregation<br />
<br />
Value 1<br />
<pre class='_prettyXprint _lang-auto _linenums:0'>
reportContext.setPersistentGlobalVariable("value1", this.value)
</pre>
<br />
Value 2<br />
<pre class='_prettyXprint _lang-auto _linenums:0'>
reportContext.setPersistentGlobalVariable("value2", this.value)
</pre>
<br />
Value 3<br />
<pre class='_prettyXprint _lang-auto _linenums:0'>
reportContext.setPersistentGlobalVariable("value2", this.value)
</pre>
<br />
You should be able to add all of those later whenever you need to.