View Single Post
  #10 (permalink)  
Old March 17th, 2010, 08:23 AM
mrame mrame is offline
Friend of Wrox
Points: 1,306, Level: 14
Points: 1,306, Level: 14 Points: 1,306, Level: 14 Points: 1,306, Level: 14
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Jun 2008
Location: Pondicherry, India
Posts: 291
Thanks: 9
Thanked 29 Times in 29 Posts
Thumbs up

With Michael Kay's idea, try inserting a root element <root> like below, and test whether the same error is shown:
Code:
<xsl:template match="/">
<root>
  <xsl:apply-templates select=".//ARXEURSL"/>
</root>
</xsl:template>
 
<xsl:template match="ARXEURSL">
 <xsl:variable name="t1" as="element(AA)*"> 
    <xsl:for-each-group select="G_ROW[INTRA_EU_TRX_CODE = ('GOODS','TRI')]" group-by="concat(VAT_TAX_NO,BILL_CUST_NAME,INTRA_EU_TRX_CODE)">
      <AA><xsl:value-of select="sum(current-group()/ACCTD_AMOUNT)"/></AA>
 
    </xsl:for-each-group>
  </xsl:variable>
    <xsl:for-each-group select="$t1" group-by="(position() - 1) idiv 3">
    <xsl:copy-of select="current-group()"/><xsl:text>&#xD;</xsl:text>
    <BB><xsl:value-of select="sum(current-group())"/></BB>
  </xsl:for-each-group>
</xsl:template>
__________________
Rummy
Reply With Quote