xsl-list
[Top] [All Lists]

RE: [xsl] Another (positional?) grouping problem

2006-10-20 02:03:24
Actually, I have to exclude an unknown number of elements 
before the first DATE, so I amended your suggestion to 
<xsl:for-each-group
select="* except /DOC/DATE[1]/preceding-sibling::*" 
group-starting-with="DATE"> and it works fine (thanks to Saxon).

The other way to achieve that would be to leave out the "except xxx", in
which case the initial nodes would go in a group of their own, and you could
eliminate that group with a test such as

<xsl:if test="current-group()[1][self::DATE]">

Michael Kay
http://www.saxonica.com/


--~------------------------------------------------------------------
XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--

<Prev in Thread] Current Thread [Next in Thread>