count different child elements
Posted: Wed Aug 22, 2018 9:26 am
Hi all,
I got a XML like
How can I count the sum of all <B1> and <B2> nodes?
count(count(/A/B1) and count(/A/B2)) --> 1 which is wrong
count(/A/B1 and /A/B2) --> 1 which is wrong
correct would be 4
Thanks
Regards
Mario
I got a XML like
Code: Select all
<?xml version="1.0" encoding="UTF-8"?>
<A>
<B1> </B1>
<B1> </B1>
<B2> </B2>
<B2> </B2>
<B3> </B3>
</A>
count(count(/A/B1) and count(/A/B2)) --> 1 which is wrong
count(/A/B1 and /A/B2) --> 1 which is wrong
correct would be 4
Thanks
Regards
Mario