[xsl] Another (positional?) grouping problem

Subject: [xsl] Another (positional?) grouping problem
From: Rudolf P. Weinmann <rudolf.weinmann@xxxxxxxxxxxx>
Date: Thu, 19 Oct 2006 15:53:36 +0200

Could anybody please tell me how to solve the following grouping problem with
xslt 2.0?

The input isn't structured. There is a root element and a sequence of
  <TEXT>text 1</TEXT>
  <TEXT>text 2</TEXT>
  <TEXT>text 3</TEXT>
  <TEXT>text 4</TEXT>
  <TEXT>Text 1</TEXT>
  <TEXT>Text 2</TEXT>

Each DATE element is the start of a group. The end of the group is either the
next DATE element or the end of the input.
I need to put the elements of each group into a <Transaction> element as

    <Text>text 1</Text>
    <Text>text 2</Text>
    <Text>text 3</Text>
    <Text>text 4</Text>
    <Text>Text 1</Text>
    <Text>Text 2</Text>

How can this be done with xslt 2.0?

Any help greatly appreciated,

Current Thread