[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

XPath question

Subject: XPath question
From: Joseph Brightly <Joseph@xxxxxxxxxxxx>
Date: Thu, 02 May 2002 19:45:47 -0700
 XPath question
I'm trying to perform an xml->xml transform and I can't seem
to be able to make it work. The following is the xml, with
extraneous stuff taken out.

I need to go from this:

<session startDate="03/23/2002" startTime="11:20:05">
<data>
    <series ID="100">
        <event time="11:20:05">65.05</event>
        <event time="11:21:05">65.23</event>
        <event time="11:22:05">67.46</event>
    </series>
    <series ID="200">
        <event time="11:20:05">40.15</event>
        <event time="11:21:05">40.17</event>
        <event time="11:22:05">40.56</event>
    </series>

    1 - N of these <series> elements...

</data>
</Session>

To this:

<session startDate="03/23/2002" startTime="11:20:05">
<data>
<series>
    <record time="11:20:05">
        <sample ID="100">65.05</sample>
        <sample ID="200">40.15</sample>
    </record>
    <record time="11:21:05">
        <sample ID="100">65.23</sample>
        <sample ID="200">40.17</sample>
    </record>
    <record time="11:22:05">
        <sample ID="100">67.46</sample>
        <sample ID="200">40.56</sample>
    </record>

    Etc...

</series>
</data>
</session>

This is something like a table join in sql, and I can't find a way
to accomplish it.

Any help would be greatly appreciated.


 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list


Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.