Wrox Programmer Forums

Need to download code?

View our list of code downloads.

Go Back   Wrox Programmer Forums > XML > XSLT
Password Reminder
| FAQ | Members List | Search | Today's Posts | Mark Forums Read
XSLT General questions and answers about XSLT. For issues strictly specific to the book XSLT 1.1 Programmers Reference, please post to that forum instead.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the XSLT section of the Wrox Programmer to Programmer discussions. This is a community of tens of thousands of software programmers and website developers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining today you can post your own programming questions, respond to other developers’ questions, and eliminate the ads that are displayed to guests. Registration is fast, simple and absolutely free .
DRM-free e-books 300x50
Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old May 11th, 2006, 01:29 PM
Registered User
Join Date: May 2006
Location: , , .
Posts: 5
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via Yahoo to daula7
Default Please help, xml transforming using xslt !!!

Hello everyone;
I have an xml that looks like the following:


<total name="test_t">
  <total name="cState">
    <total name="date_range">
      <value >00-06 </value>
    <total name="date_range">
      <value >07-12 </value>
    <total name="date_range">
      <value>13-24 </value>
  <total name="cState">
    <total name="date_range">
      <value >00-06 </value>
    <total name="date_range">
      <value >07-12 </value>
    <total name="date_range">
      <value>13-24 </value>


my xslt follows:
<xsl:stylesheet version='1.0' xmlns:xsl='http://www.w3.org/1999/XSL/Transform'>
   <xsl:template match="/" >

   <xsl:text> _Total_ </xsl:text>
     <xsl:for-each select=

       <xsl:value-of select="value"/>
       <xsl:text>: </xsl:text>
       <xsl:for-each select="key('range',value)">
          <xsl:value-of select="sum(count)"/>
          <xsl:text >,</xsl:text>



I'm seeeking more help in using xslt for transformation/ retrieve data such that, to display the sum of "count" by "date_range" for all states.
For instance:

00-06 : 71
07-12 : 36

et cetera...

However, when I try to diplay the output... I'm getting a blank screen. I desperately need your help.
Please, note that I'm using xslt 1.0

Thanks in advance for your kind assistance

Reply With Quote

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Show CURRENT DATE when transforming XML using XSLT richieWolf XSLT 0 October 20th, 2007 07:47 PM
Exception when transforming using XSLT ksskumar XSLT 5 October 10th, 2006 06:20 AM
problem transforming XML using xslt micky3248 XSLT 7 August 18th, 2006 03:52 AM
Transforming XML data in an ASP file using XSLT hussainm Classic ASP XML 0 May 31st, 2006 03:21 PM
Transforming a result tree with yet another Xslt ballo XSLT 2 March 7th, 2006 09:42 AM

All times are GMT -4. The time now is 06:10 AM.

Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.