• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Tim Cooke
  • paul wheaton
  • Jeanne Boyarsky
  • Ron McLeod
Sheriffs:
  • Paul Clapham
  • Liutauras Vilda
  • Devaka Cooray
Saloon Keepers:
  • Tim Holloway
  • Roland Mueller
Bartenders:

Jasper and Struts

 
Ranch Hand
Posts: 18944
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi there !
I�m using Struts and need a free report generator in my project. After having searched for a good option , I�ve chosen JasperReports.
In fact I consider the report to be a view tier for me ... so I need to populate the beans and objects in general for using them in the report. I expected being able to iterate objects and print them the same way you do in a .jsp page ... or a Velocity template, but , surprisingly , it seems to be impossible for JasperReports, to get the objects and render them in the .xml ... Instead I need to define the query I have to use to get the data I need...
Is it really impossible to post the ready data to Jasper so it can use it to render the report ? I tried to do this via �parameter� tag , but it wasn�t possible ?
How do I do this ?
Has anybody used Struts together with Jasper or any other report generator ?
Thanx in advance !
F�bio
 
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Instead of defining a query directly in the report template, it is also possible to use a instance of JRDataSource. JasperReport provides default implementation supporting ResultSet and Collection.
 
I wasn't selected to go to mars. This tiny ad got in ahead of me:
We need your help - Coderanch server fundraiser
https://coderanch.com/wiki/782867/Coderanch-server-fundraiser
reply
    Bookmark Topic Watch Topic
  • New Topic