[xquery-talk] Returning "pre-pos" context
Elarrat, EFC
eduardoelarrat at gmail.com
Thu Jan 5 13:26:38 PST 2006
Happy new year everybody
I have this xml structure
<s>
<tok>
<orth>dataxxx</orth>
<lex>
<ctag>datayyy</ctag>
</lex>
</tok>
...(mani tok tags for a s tag)
</s>
I tried to do the following:
find the tags that contains some data beginning with d (for example) on the
ORTH tag - Ok You guys already helped me with that
find the tags that contains some data beginning with d (for example) on the
CTAG tag - Ok You guys already helped me with that
find the tags that contains some data beginning with d (for example) on the
ORTH AND the CTAG tag - Ok You guys already helped me with that
And now the hard one (for me, of course)
within the rules above, I would like to find the same as before, but with
some others tags before it, and some others tag after it. It's hard to
explain...so I'm going to give an example:
This xml
<s>
<tok>
<orth>AA</orth>
<lex>
<ctag>XX</ctag>
</lex>
</tok>
<tok>
<orth>BB</orth>
<lex>
<ctag>YY</ctag>
</lex>
</tok>
<tok>
<orth>CC</orth>
<lex>
<ctag>ZZ</ctag>
</lex>
</tok>
</s>
What I would like to do, is to find the BB, but with the AA and the CC with
it, so the final return value would be like: AA BB CC.
Is it possible to do something like this? Thanks for you attention.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://xquery.com/pipermail/talk/attachments/20060105/255be9cb/attachment.htm
More information about the talk
mailing list