RE: sorted for-each: preceding::sibling is not in sort
> > XSLT 2.0 allows you to use xsl:sequence > > instead of xsl:copy-of, so you can construct a variable > whose value is a > > sequence of nodes (node references) without making copies > of the nodes. > > Wouldn't I once again have the problem with > preceding::sibling when they are references? Yes, this doesn't enable you to use preceding-sibling; what it does do is to enable you to create a variable whose value is a sorted sequence of nodes, each of which retains its original owner and children, etc, without copying the nodes; you can then process this sequence using a variety of new XSLT 2.0 and XPath 2.0 constructs that make it unnecessary to use preceding-sibling. IIRC correctly, though, your problem was a grouping problem in which case you can probably solve it directly using XSLT 2.0's for-each-group construct. Michael Kay http://www.saxonica.com/
PURCHASE STYLUS STUDIO ONLINE TODAY!
Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!
Download The World's Best XML IDE!
Accelerate XML development with our award-winning XML IDE - Download a free trial today!
Subscribe in XML format