Jump to content

XML datasource only prints the first record


lkennedy

Recommended Posts

Hi all,

 

I am creating a report which reads its data from an XML data source. I am able to retrieve parameters using xpath successfully, but where they are repreated, I only get the first one. Di I have to do anything special to iterate through all the records ?

Do I have to use a sub report for this ?

 

My xpath expression returns all the records I expect in other tools, so I know its something to do with iReport/jasper.

 

Thanks for your help !

Link to comment
Share on other sites

  • 2 weeks later...
  • Replies 3
  • Created
  • Last Reply

Top Posters In This Topic

Top Posters In This Topic

  • 5 weeks later...
I'm seeing the same thing with both 1.3.1 and 1.3.2. I get a detail band entry for each record in my XML, but the same information from the first record is displayed in each. Some general info for header data is displayed correctly, and comes from a different XPath than the data records. Ideas?
Link to comment
Share on other sites

Hallo,

try using subreports. In the master report use the <dataSourceExpression> to verify your XPath in the subreport Tag.

I had the same problem & could only fix it using subreport.

 

Hope it helps.

 

Regards

Fatsy

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...