xml - What is the xpath to select a range of nodes? -
Hello, I have an XML file that is structured like this:
  Lt; Foo & gt; & Lt; Bars & gt; & Lt; / Bars & gt; & Lt; Bars & gt; & Lt; / Bars & gt; ... & lt; / Foo & gt;   I do not know how to catch several nodes. Someone gives me an example of an xpath expression that holds nodes 100-200 times.
:
  / * / Bar [position () & gt; = 100 and not (status ()> 200)]   Note :
-  the exact form From barelements are selected from 100 to 200 (inclusive).
-  The evaluation of this XPath expression can be manifold faster than expression using //short name, because of the latter tree Try to avoid using the root reference node always possible to avoid using//short name in such cases.
Comments
Post a Comment