Re: Variable references in path expressions
martin <[email protected]> Thu, 28 Apr 2005 11:36:22 +0200
| Newsgroups | gmane.comp.web.query-languages |
|---|---|
| Message-ID | <[email protected]> |
>>I suggest that the atomic values returning from the last
>>step must be a result of evaluating against the preceding
>>step. Wherein the above example, there should be an
>>attempt to convert each item into a QName
>
>
> I don't understand this notion of converting things into QNames.
>
> In a conventional path expression such as a/following-sibling::*, how would
> I convert following-sibling::* into a QName?
I might be mistaken, but I think he wants to do this:
> let $a := (<a/>,<b/>,<c/>)
> let $b := (xs:QName("b"), xs:QName("c"))
> return $a/$b
.. would lead to $a being filtered by $b's QNames on the child axis, so
the result would be <b/>,<c/> (e.g. what you would get by
$a/element($b)). I've noticed that some people tend to understand
Variable references in XQuery PathSteps this way.
Regards,
Martin