Jump to content
We've recently updated our Privacy Statement, available here ×

Help with percentages in crosstabs


wahoyaho

Recommended Posts

  • Replies 2
  • Created
  • Last Reply

Top Posters In This Topic

Popular Days

Top Posters In This Topic

You can make a percentage respect each asingle row/column total.

 

I.e. to have the percentage of the single year respect to all the time use:

 

Code:

new Double($V{FreightSum_ShipMonth_ALL}.doubleValue() / $V{FreightSum_ShipYear_ALL}.doubleValue())

 

Or to have the percentage of each single month respect to the current year:

 

Code:
[code]
new Double($V{FreightSum}.doubleValue()/$V{FreightSum_ShipMonth_ALL}.doubleValue())

 

 

Attached there is a sample you can run using the database shipped with JasperReports.

 

Giulio [file name=crosstab.zip size=8031]http://www.jasperforge.org/components/com_joomlaboard/uploaded/files/crosstab.zip[/file]

Link to comment
Share on other sites

Thanks for the fast reply, just a quick question, how can I make a variable that is total of each day?

 

For example, the first table in

http://www.fortinet.com/FortiLogdemo/file/Network_Activity.html

 

I can get the subtotal % values to show up correctly with Grand Total percentage provided in the crosstab options, but how can I get the % for the unclassified values?

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×
×
  • Create New...