xsl:for-each-group

Allocates the items in an input sequence into groups of items (that is, it establishes a collection of sequences) based either on common values of a grouping key, or on a pattern that the initial or final node in a group must match.

Format

<xsl:for-each-group
               
  select = expression
               
  [group-by = expression]
               
  [group-adjacent = expression]
               
  [group-starting-with = pattern]
               
  [group-ending-with = pattern]
               
  [collation = { uri }>
               
  <!-- Content: (xsl:sort*, sequence-constructor) -->
               
</xsl:for-each-group>
               

            

Description

The xsl:for-each-group element is an instruction that can be used anywhere within a sequence constructor. The sequence of items to be grouped is referred to as a population. A group cannot be empty. If the population is zero (that is, empty), the number of groups is zero. How items are assigned to groups is determined by the group-by, group-adjacent, group-starting-with, and group-ending-with attributes.

Microsoft .NET XML Tools for System.XML 1.0 and System.XML 2.0

Stylus Studio features integrated XML validation, XSLT transformation and XSLT debugging using the official Microsoft .NET XML processing components: System.XML 1.0 and System.XML 2.0.

Convert DTD to XSD

learn how to convert DTD to XML Schema

XSL-List

The XSL-List forum is a valuable learning resource for the Extensible Stylesheet Language (XSL), covering the XSL specification, XSL processor implementations, and XSL user questions. Get this free XSL resource delivered to your inbox today.

Xerces - Parsing and Validating XML with the Apache Xerces Parser

The Xerces Parser supports the XML 1.0 recommendation and W3C's XML Schema recommendation version 1.0, DOM and SAX. Learn how easy it is to use Apache Xerces directly in Stylus Studio to parse and validate XML with ease.

Stylus Most Wanted

 
Free Stylus Studio XML Training:
W3C Member