|
Subject: Re: Grouping in the FAQ (was Re: Conflicting Node Values) From: David Carlisle <davidc@xxxxxxxxx> Date: Fri, 26 May 2000 12:24:08 +0100 (BST) |
I wrote
> Don't you want
>
> count(.|key('tid',.)[1])=1
>
> which is equivalent to the generate-id tests.
Of course, it's only equivalent in the case that you know that the
key returns something, otherwise if the key returns the empty set then
the above will always be true as .|key('tid',.)[1] will be .
In general the test
"is the current node the first node in the node set x"
is either
"generate-id(.) = generate-id($x[1])" (the [1] is optional here)
or
"count(.|$x[1])=count($x[1])"
or
"$x and count(.|$x[1])= 1"
David
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
| Current Thread |
|---|
|
| <- Previous | Index | Next -> |
|---|---|---|
| Re: Grouping in the FAQ (was Re: Co, David Carlisle | Thread | RE: Grouping in the FAQ (was Re: Co, Kay Michael |
| RE: Portal applications using XSL, Paulo Gaspar | Date | RE: Grouping in the FAQ (was Re: Co, Kay Michael |
| Month |