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

RE: RE: possible nested loops

Subject: RE: RE: possible nested loops
From: cknell@xxxxxxxxxx
Date: Wed, 15 Feb 2006 09:25:03 -0500
RE: RE:  possible nested loops
Please show an example of what this means:

> return each country's data as one block before the next
-- 
Charles Knell
cknell@xxxxxxxxxx - email



-----Original Message-----
From:     garry@xxxxxxxxxxxxxxxxxxx
Sent:     Wed, 15 Feb 2006 08:07:45 -0000 (GMT)
To:       xsl-list@xxxxxxxxxxxxxxxxxxxxxx
Subject:  RE:  possible nested loops

This would give a better approximation to what I have.

<country>
<name></name>
> <state>
>    <city/>
>    <city>
> </state>
> <state>
>    <city/>
>    <city>
> </state>
> <state>
>    <city/>
>    <city>
      <city/>
>    <city>
      <city/>
>    <city>
> </state>
> </country>
<country>
<name></name>
> <state>
>    <city/>
>    <city>
> </state>
> <state>
>    <city/>
>    <city>
> </state>
> <state>
>    <city/>
>    <city>
> </state>
> </country

I need to return each country's data as one block before the next. When I
use code such as that on page 615 of Michael Kay's book - XSLT 2 (fill in
the blanks type) I can get the country name to repeat:

<xsl:for-each select="//country">
<xsl-if test="name"><input name="country.name:records"
value="{name}"></xsl-if>
</xsl-for-each>

But when I use another for-each loop inside this I get spurious results
when applied to an xml document containing 2 pupil records and if I apply
it to my 800 plus record xml doc, Oxygen runs out of memory and xmlSpy
dies during the transformation.
I am on another machine here so I can't post the original docs at present
but will do later if it would help.
regards
garry

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.