- Based on the syntax of XPath 2.0 (like XPath 1.0 but includes, eg, a dereference operator)
In the second chapter of the document named "zoo.xml", find the figure(s) with caption "Tree Frogs":
document("zoo.xml")/chapter[2]//figure[caption = "Tree Frogs"]
Find captions of figures that are referenced by <figref> elements in the chapter of "zoo.xml" with title "Frogs".
document("zoo.xml")/chapter[title = "Frogs"]//figref/@refid=>fig/caption