[xquery-talk] XQuery and id()/idref(); Controlling the children of
nodes in the result sequence
Maik Stührenberg
maik.stuehrenberg at uni-bielefeld.de
Wed Apr 23 16:47:28 PDT 2008
Michael Kay schrieb:
>> So the question is, is it possible to recursively traverse
>> the descendants of the a:data node and select only those
>> element nodes which
>> refer to the same a:span element?
>
> Well, the answer is yes - though at this point I'm afraid I start wishing
> the code was written in XSLT rather than XQuery: XSLT makes recursive
> traversal of a tree so much easier. But you can do it: write a recursive
> function that you apply to a node, and which calls itself to process the
> children of the node.
>
>
To be honest, I started writing an XSLT script after my first steps in
the XQuery world. So I guess in XSLT I'd need a template for the a:data
node containing a xsl:for-each select="child::node" statement...
Kind regards,
Maik Stührenberg
More information about the talk
mailing list