[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

RE: group data in XSL

Subject: RE: group data in XSL
From: "Michael Kay" <mhk@xxxxxxxxx>
Date: Thu, 19 Aug 2004 10:07:05 +0100
the xml declaration is unexpected
I don't think you understood the reply to you original message.

<xsl:for-each-group> is an XSLT 2.0 construct. To use it, you need an XSLT
2.0 processor. The only XSLT 2.0 processor available at present is Saxon
(currently version 8.0). Any XSLT 1.0 processor will report an error if it
sees this construct.

Michael Kay
 

> -----Original Message-----
> From: Tham Tinh [mailto:khautinh@xxxxxxxxx] 
> Sent: 19 August 2004 00:05
> To: xsl-list@xxxxxxxxxxxxxxxxxxxxxx
> Subject: RE:  group data in XSL
> 
> Please Help.
> 
> Error still when I put my xml.xml and xsl.xslt
> together in ASP.NET and use with xml control.
> 
> I saved the following code as xsl.xslt
> 
> <?xml version="1.0"?>
> <xsl:stylesheet version="1.0"
> xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
> 	<xsl:template match="/">
> 		<xsl:for-each-group select="/dsWMSRpt/WMSReport"
> group-by="ReportUnitTitle">
> 				Administration Code: <xsl:value-of
> select="AdministrationCode"/>
> 				Report Title:        <xsl:value-of
> select="ReportUnitTitle"/>
> 				<!--xsl:for-each
> select="current-group()/PositionNumber"-->
> 					Position Number: <xsl:value-of
> select="PositionNumber"/>
> 				<!--/xsl:for-each-->
> 		</xsl:for-each-group>
> 	</xsl:template>
> </xsl:stylesheet>
> 
> 
> And the following as xml.xml
> 
> 
>  <?xml version="1.0" standalone="yes"?>
> 
>  <dsWMSRpt>
>  	<WMSReport>
>  		<AdministrationCode>ABC</AdministrationCode>
>  		<ReportUnitTitle>Financial Div</ReportUnitTitle>
>  		<PositionNumber> 0934</PositionNumber>
>  	</WMSReport>
>  	<WMSReport>
>  		<AdministrationCode>ABC</AdministrationCode>
>  		<ReportUnitTitle>Part Div</ReportUnitTitle>
>  		<PositionNumber> 4563</PositionNumber>
>  	</WMSReport>
>  	<WMSReport>
>  		<AdministrationCode>ABC</AdministrationCode>
>  		<ReportUnitTitle>Financial Div</ReportUnitTitle>
>  		<PositionNumber> K948</PositionNumber>
>  	</WMSReport>
>  	<WMSReport>
>  		<AdministrationCode>ABC</AdministrationCode>
>  		<ReportUnitTitle>Human Resource
> Div</ReportUnitTitle>
>  		<PositionNumber> 6453</PositionNumber>
>  	</WMSReport>
>  	<WMSReport>
>  		<AdministrationCode>ABC</AdministrationCode>
>  		<ReportUnitTitle>HumanResource
> Div</ReportUnitTitle>
>  		<PositionNumber> 9655</PositionNumber>
>  	</WMSReport>
>  	<WMSReport>
>  		<AdministrationCode>ABC</AdministrationCode>
>  		<ReportUnitTitle>Sale Div</ReportUnitTitle>
>  		<PositionNumber> SDWE</PositionNumber>
>  	</WMSReport>
>  	<WMSReport>
>  		<AdministrationCode>ABC</AdministrationCode>
>  		<ReportUnitTitle>Sale Div</ReportUnitTitle>
>  		<PositionNumber> 4577</PositionNumber>
>  	</WMSReport>
>  </dsWMSRpt>
> 
> Error:
> 
> Server Error in '/TransformationTest' Application.
> The XML declaration is unexpected. Line 1, position 4.
> 
> Description: An unhandled exception occurred during
> the execution of the current web request. Please
> review the stack trace for more information about the
> error and where it originated in the code. 
> 
> Exception Details: System.Xml.XmlException: The XML
> declaration is unexpected. Line 1, position 4.
> 
> 
> =====
> "It is essential to know that to be a happy person, a happy 
> family, a happy society, it is very crucial to have a good 
> heart, that is very crucial,"
> Dalai Lama
> 
> 
> 		
> __________________________________
> Do you Yahoo!?
> Yahoo! Mail Address AutoComplete - You start. We finish.
> http://promotions.yahoo.com/new_mail 

Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.