[Home] [By Thread] [By Date] [Recent Entries]
Hi Martin and David,
You both cleared up the fact that the group-by formulation is not the likely cause of failure, so now I know that it is not the fundamental reason for the failure and I will investigate further. Thanks, Mark -----Original Message----- From: David Carlisle Sent: Tuesday, November 22, 2011 10:23 AM To: xsl-list@xxxxxxxxxxxxxxxxxxxxxx Cc: Mark Subject: Re: group-by an optional attribute On 22/11/2011 17:12, Mark wrote: Hi, Consider: <xsl:for-each-group select="current-group()" group-by="Stamp/@line" You don't say how it fails. what you wrote should be legal but whether it "works" depends on how you want things to group. I find <xsl:for-each-group select="current-group()" group-by="string(Stamp/@line)" usually does what I want in these situations, but whether it does what you want, I can't guess:-) if you select nothing then things go in no group, but by using string() you never select nothing and things without the attribute end up in the group keyed on the string "". this assumes that there is at most one Stamp child. David -- google plus: https:/profiles.google.com/d.p.carlisle ________________________________________________________________________ The Numerical Algorithms Group Ltd is a company registered in England and Wales with company number 1249803. The registered office is: Wilkinson House, Jordan Hill Road, Oxford OX2 8DR, United Kingdom. This e-mail has been scanned for all viruses by Star. The service is powered by MessageLabs. ________________________________________________________________________
|

Cart



