I have this xml document :
<AAA>
<CCC>
<BBB>SALAM</BBB>
<BBB>HALET KHUBE</BBB>
<BBB>HEY</BBB>
<TTT>SALAM</TTT>
<GGG/>
<ZZZ/>
</CCC>
<DDD>
<BBB>GOOD</BBB>
<BBB>BOOO</BBB>
<GGG/>
<GGG/>
<ZZZ/>
</DDD>
<EEE>
<CCC>TAKE</CCC>
<DDD>LEAVE</DDD>
<ZZZ/>
<ZZZ/>
<ZZZ/>
</EEE>
</AAA>
I want to select nodes that have 2 children with text = “SALAM” ( that node can have any number of children but it must have 2 chidren with text = “SALAM”) .For example in above xml ,the xpath query must return CCC tag.
please help me.
thanks
Use:
It may be more efficient to use the following:
Always when possible try to avoid using the
//pseudo-operator, because in many cases it can be very slow.