Say I have a collection c with xml documents x.xml, y.xml, and z.xml and
that I've added them using "to" so that they are found here:
collection('c/x')
...
Let's say that in each document I have a node <code/>, so in x.xml I have
<code id='1'/>, in y.xml I have <code id='2'/>, etc.
I can query across the documents to find the <code/> node with id = 2
pretty easily. But now that I've found it, I want to do further queries
limiting myself to that document. In other words, I want to learn using
XQuery that the <code/> node with id = 2 is in collection('c/y').
How can I do this?
TIA,
Chas.