[Date Prev]
| [Thread Prev]
| [Thread Next]
| [Date Next]
--
[Date Index]
| [Thread Index]
RE: [xml-dev] XPath on sequences of nodes
- From: "Michael Kay" <mike@saxonica.com>
- To: "'David Carlisle'" <davidc@nag.co.uk>,<gottif@iro.umontreal.ca>
- Date: Fri, 12 Jan 2007 17:43:07 -0000
Another suggestion: perform-sort is efficient because it creates a new
sorted sequence without actually copying the nodes. But if you created a
temporary tree in this situation, that is, if you copied the nodes to create
new nodes, then the document order of the new nodes would reflect your
sorted sequence and "/" would not disturb it.
Michael Kay
http://www.saxonica.com/
> -----Original Message-----
> From: David Carlisle [mailto:davidc@nag.co.uk]
> Sent: 12 January 2007 17:25
> To: gottif@iro.umontreal.ca
> Cc: xml-dev@lists.xml.org
> Subject: Re: [xml-dev] XPath on sequences of nodes
>
>
>
> > For the life of me, I don't know what's happening. How can
> a variable
> > store 2 different results? I'd really appreciate it if
> someone could
> > give me a hint.
>
> most operations on nodes, including / are defined to return
> their reults in document order, with duplicates removed, so
> $x/. is one way to reorder and de-duplicate a sequence for example.
>
> You have $selectedSents/c so you reorder.
>
> for $x in $selectedSents return $x/c
>
> would not reorder.
>
> David
>
> ______________________________________________________________
> _________
>
> XML-DEV is a publicly archived, unmoderated list hosted by
> OASIS to support XML implementation and development. To
> minimize spam in the archives, you must subscribe before posting.
>
> [Un]Subscribe/change address: http://www.oasis-open.org/mlmanage/
> Or unsubscribe: xml-dev-unsubscribe@lists.xml.org
> subscribe: xml-dev-subscribe@lists.xml.org List archive:
> http://lists.xml.org/archives/xml-dev/
> List Guidelines: http://www.oasis-open.org/maillists/guidelines.php
>
[Date Prev]
| [Thread Prev]
| [Thread Next]
| [Date Next]
--
[Date Index]
| [Thread Index]