I use in my csharp code this xml:
<doc>
<item Id="1">
<item>1</item>
</item>
<item Id="1">
<item>2</item>
</item>
<item Id="2">
<item>A</item>
</item>
<item Id="3">
<item>B</item>
</item>
</doc>
And I need to exclude all items that Id="1" and then in the result set, get
the a range of nodes, for exmpale the first to third nodes.
I use this /doc/item[@Id != "1" and (position() >0 and position() <= 2) ]
but there is no result, why ?
Thanks for help.
Sam
<doc>
<item Id="1">
<item>1</item>
</item>
<item Id="1">
<item>2</item>
</item>
<item Id="2">
<item>A</item>
</item>
<item Id="3">
<item>B</item>
</item>
</doc>
And I need to exclude all items that Id="1" and then in the result set, get
the a range of nodes, for exmpale the first to third nodes.
I use this /doc/item[@Id != "1" and (position() >0 and position() <= 2) ]
but there is no result, why ?
Thanks for help.
Sam
Comment