gan
-
Posts
8 -
Joined
-
Last visited
Content Type
Forum
Downloads
Featured Visualizations
Knowledge Base
Documentation (PDF Downloads)
Blog
Documentation (Test Area)
Documentation
Dr. Jaspersoft Webinar Series
Security Advisories
Events
Profiles
Posts posted by gan
-
-
Hi,
Instead of trying to calculate the "y" position, you can set sub-reports with the Position Type to "Float", flag the "Remove line when blank" and set up a "Print when expression" that evaluate the choosed options.
I work with IReport though, so I can't be really precise on how to implement it into your application.
I hope it sends you into the right track.
Gan
-
I am trying to build a report with running percentage.
A "sum" variable evaluated "now" will effectively calculate a running sum of a field. The same variable, evaluated "report" will provide the total sum. How can I divide the running sum with the total sum, i.e. calculate and display the running percentage?
I am including an example report.
[file name=RunPerc-c837e9154419bf47250c4e8bb940853a.jrxml size=12551]http://www.jasperforge.org/components/com_joomlaboard/uploaded/files/RunPerc-c837e9154419bf47250c4e8bb940853a.jrxml[/file]
Thanks in advance for the help.
-
Yes, it is "sum" and F$
I've attached an example report, give it a look.
[file name=RunPerc.jrxml size=11917]http://www.jasperforge.org/components/com_joomlaboard/uploaded/files/RunPerc.jrxml[/file]
-
Well, I would have expected a total for the column, not the double of the current line.
The tricky point with running percentage is that I need the same "sum" variable computed twice: "now" and "report". The first instance will return the running sum, the second the total sum.
I still don't have a solution for it.
-
Does not work.
I tried to display the variable on a dedicated textfield to verify its behaviour, what I get is the double of the field value. The textfield is evaluated "now", the variable is reset to "none".
:S
-
Schaibaa,
I agree on the fact that texfields and variables are different entities.
The point is that the variable is the same (a "sum" variable on a field), just evaluated (computed) at different times: "now" for running sum, "report" for total. To my knowledge, "evaluation time" can be done only with textfield, so here is where I am stuck, since I can't choose two different evaluation time for the same variable, in a formula.
But maybe I am on a wrong track and there is a different solution for my running percentage request. I just can't figure it out right now...
-
I am trying to do a report with running sums and percentage.
Using a "sum" variable and a textfield with evaluation time "now" I can have a running sum. A second textfield, eventually hidden, with evaluation time "report" would provide the total sum to each line of the report.
Last step, where I'm stuck, would be to set a textfield with evaluation time "now", that divide the running sum variable with the content of the hidden field (total sum).
How can I retrieve the content of a textfield from another one?
The report would look like something like:
Item Val RunSum RunPerc
----- --- ------ -------
Item1 10 10 25%
Item2 10 20 50%
Item3 20 40 100%
----- --- ------ -------
Thanks in advance to all contributors.
Giovanni
Running Percentages
in Products
Posted
Thank you very much, that solved my misery :)
Gan