This week's book giveaway is in the Reactive Progamming forum.
We're giving away four copies of Reactive Streams in Java: Concurrency with RxJava, Reactor, and Akka Streams and have Adam Davis on-line!
See this thread for details.
Win a copy of Reactive Streams in Java: Concurrency with RxJava, Reactor, and Akka Streams this week in the Reactive Progamming forum!
  • 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 all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Liutauras Vilda
  • Junilu Lacar
  • Jeanne Boyarsky
  • Bear Bibeault
Sheriffs:
  • Knute Snortum
  • Tim Cooke
  • Devaka Cooray
Saloon Keepers:
  • Ron McLeod
  • Stephan van Hulst
  • Tim Moores
  • Tim Holloway
  • Carey Brown
Bartenders:
  • Piet Souris
  • Frits Walraven
  • Ganesh Patekar

Jasper Reports Cookbook- userdefined XML to PDF possible

 
Greenhorn
Posts: 9
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Bilal,

Good Day!


I am working in Temenos . A banking product company,

I learn this Jasper Reports from www.nebteans.org one article, From that onwards i used this jasper reports to my college final year projects.

But all examples are i hands on from data base,

Our company product don't have inbuilt customized reporting tool. I R&D personally for few months out of my work to implement this jasper reports
to our T24 product.

I have formed user defined or customized xml from our product , I wish to populate to jasper reports , Is it possible to convert the attached xml to customized JRXML.


Please find the xml and its schema.

Customized or User-defined XML




Customized or User-defined SCHEMA xsd



Many Thanks

vidhyadharan D





 
author
Posts: 3281
8
Mac OS X Eclipse IDE Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi there,

This should certainly be possible using a XSL stylesheet!
 
Vidhya DeivaMani
Greenhorn
Posts: 9
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Can you please give me some example

Many Thanks
vidhya
 
Martijn Verburg
author
Posts: 3281
8
Mac OS X Eclipse IDE Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Well I've never tried your specific use case before but using a style sheet to transform an XML document that meets one schema to another XML document that meets a second schema is quite common. I sugget you start here!
 
Author
Posts: 17
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello Vidhya,

JasperReports provides full flexibility of using a wide variety of datasources including XML.

Acting as a consultant for an energy meter manufacturing company, I designed the XML schema to represent energy consumption data of a metropolitan city. The city had many grid stations, each grid station had several feeders, each feeder was feeding into a number of transformers and eventually each transformer was connected to a few dozen electricity consumers. I used JasperReports to provide a set of very comprehensive reports about the energy consumption data of the entire city consisting of over a million consumers.

So, customized XML is no problem for JasperReports. You can use XPath to map data elements from your XML to JasperReports data fields. Then you design your Jasper report using the data fields.

This extract from my JasperReports book is a step-by-step demonstration of creating a Report from customized XML using XPath.

http://www.packtpub.com/article/jasperreports-creating-report-from-xml-data-using-xpath

Please try this recipe and I hope it will show you exactly what you need to do with your customized XML in order to generate a report. And, if you have a spec of time, please let us all know on this forum what you learned from my recipe.
 
I'm gonna teach you a lesson! Start by looking at this tiny ad:
Java file APIs (DOC, XLS, PDF, and many more)
https://products.aspose.com/total/java
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!