This week's book giveaway is in the Servlets forum.
We're giving away four copies of Murach's Java Servlets and JSP and have Joel Murach on-line!
See this thread for details.
The moose likes XML and Related Technologies and the fly likes XSL transformation Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Engineering » XML and Related Technologies
Bookmark "XSL transformation" Watch "XSL transformation" New topic

XSL transformation

neha gowda

Joined: Feb 04, 2004
Posts: 23

<ALLOCATION START="2008-03-01" FTE="1.0" />
<ALLOCATION START="2008-04-01" FTE="1.0" />
<ALLOCATION START="2008-05-01" FTE="0.56" />
<ALLOCATION START="2008-06-01" FTE="0.5" />
<ALLOCATION START="2008-07-01" FTE="1.0" />
<ALLOCATION START="2008-08-01" FTE="0.5" />
<ALLOCATION START="2008-02-01" FTE="1.0" />
<ALLOCATION START="2008-03-01" FTE="2.0" />
<ALLOCATION START="2008-04-01" FTE="3.75" />
<ALLOCATION START="2008-05-01" FTE="2.0" />
<ALLOCATION START="2008-06-01" FTE="1.5" />
<ALLOCATION START="2008-07-01" FTE="1.5" />
<ALLOCATION START="2008-08-01" FTE="0.5" />
<ALLOCATION START="2008-09-01" FTE="0.25" />
<ALLOCATION START="2008-10-01" FTE="0.12" />

I'm generating this xml using a xsl. I have to add FTE values with same date
and the XML shd be

<ALLOCATION START="2008-03-01" FTE="3.0" />
<ALLOCATION START="2008-04-01" FTE="4.75" />
<ALLOCATION START="2008-05-01" FTE="2.56" />
<ALLOCATION START="2008-06-01" FTE="2.0" />
<ALLOCATION START="2008-07-01" FTE="3.0" />
<ALLOCATION START="2008-08-01" FTE="0.5" />
<ALLOCATION START="2008-02-01" FTE="1.0" />
<ALLOCATION START="2008-09-01" FTE="0.25" />
<ALLOCATION START="2008-10-01" FTE="0.12" />

How do I do it.

Balaji Loganathan
author and deputy

Joined: Jul 13, 2001
Posts: 3150
Have tried applying xsl:sort over start attribute in the xsl:for-each loop ??

if you are a beginner for xslt, please have a look at this tutorial

Spritle Software Blogs
I agree. Here's the link:
subject: XSL transformation
Similar Threads
Maximum Sum Project!!
How would i break this down into seperate metods?
Problem moving columns and rows in 2D array.
Which version to begin?