Jump to content

Recommended Posts

Posted

Hi,

I'm quite new to Jasper and I'm facing a blocking problem.

I have an XML source like this:

<items> <item>  <name>John</name>  <activities>   <activity number="1">First activity</activity>   <activity number="2">Second activity</activity>   <activity number="3">Third activity</activity>  </activities>  <durations>   <duration number="1">1 hour</duration>   <duration number="2">1 day</duration>   <duration number="3">2 days</duration>  </durations>  <descriptions>   <description number="1">something short</description>   <description number="2"></description>   <description number="3">something long</description>  </descriptions> </item><item>  <name>Paul</name>  <activities>  <activity number="1">Second activity</activity>  <activity number="2">Another activity</activity> </activities>  <durations>  <duration number="1">2 days</duration>  <duration number="2">2 hours</duration>  </durations>  <descriptions>   <description number="1"/>  <description number="2"/> </descriptions> </item><item>.....</item> </items>

I need to produce a table grouped like this

NameActivity NameDurationDescription
JohnFirst activity1 hoursomething short
 Second activity1 day 
 Third activity2 dayssomething long
PaulSecond activity2 days 
 Another activity2 hours 

but I cannot find a way to group activity details (activity name, duration, description) to act like rows.

Is there a way to handle this completely inside a single jrxml file without changing XML source structure?

 

Please help,

-MR

  • Replies 0
  • Created
  • Last Reply

Top Posters In This Topic

Popular Days

Top Posters In This Topic

Popular Days

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