|
[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] RE: Duplicates
> Can anyone tell me what is meant here by the word
> 'duplicates'? When is a node considered a duplicate of another node?
Loosely, two nodes are duplicates if they are derived from the same
syntactic unit of the same source XML document. (I don't like "two nodes are
duplicates", as they are then one node, but I did say "loosely".) It's based
on identity, not on the node's string-value.
There are some special rules to refine this definition:
- namespace nodes are copied between elements rather than being shared
- "the same source XML document" means "accessed using an identical URI".
The root nodes returned by document("books.xml") and by
document("BOOKS.xml") are different nodes, even if they both URIs retrieved
the same file.
Mike Kay
PS: Saxon 5.2 has an extension function distinct() which eliminates nodes
from a node-set that have a duplicate string-value. Another way of doing
grouping.
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|

Cart








