Hi,
In "XQuery and XPath Full Text 1.0 Use Cases" [1] it says:
Querying across element boundaries is similar to an XQuery and XPath character string function converting the sub-tree under an element into a string by removing all markup.
However, I'm having trouble to get this to work in BaseX 7.2.1. For example, given this document:
<doc> <p id="1">Lorem ipsum dolor sit amet</p> <p id="2">Lorem ipsum dolor sit amet</p> <p id="3">Lorem ipsum dolor <i>sit</i> amet</p> <p id="4">Lorem ipsum <i>dolor sit</i> amet</p> </doc>
How do I query, for example, for p elements that contain the string "sit amet"?
//p[. contains text 'sit amet']
returns only paragraphs 1 and 2. I've tried a number of variations, but I've been unable to come up with a query that returns all four p elements.
Are my queries incorrect or is this a bug in BaseX?
Thanks and best regards
Footnotes: [1] http://www.w3.org/TR/xpath-full-text-10-use-cases/