I'm having trouble to retrieve all the parents for repeating child name.
<NCAAScores>
<levels>
<level>
<name>Western Conference</name>
<teams>
<team>
<name>Dallas Stars</name>
<scorable>
<win>60</win>
<lose>35</lose>
</scorable>
</team>
<team>
<name>Chicago Blackhawks</name>
<scorable>
<win>60</win>
<lose>23</lose>
</scorable>
</team>
<team>
<name>Edmonton Oilers</name>
<scorable>
<win>55</win>
<lose>9</lose>
</scorable>
</team>
<team>
<name>Philadelphia Flyers</name>
<scorable>
<win>5</win>
<lose>9</lose>
</scorable>
</team>
</teams>
</level>
<level>
<name>Eastern Conference</name>
<teams>
<team>
<name>Dallas Stars</name>
<scorable>
<win>1</win>
<lose>34</lose>
</scorable>
</team>
<!---And so on, you get the idea-->
</teams>
</level>
</levels>
</NCAAScores>
If I want to retrieve all of the parent level having team "Dallas Stars" what would be the approach?
I tried with below
./levels[/level/teams/team/name = 'Dallas Stars']
, which didn't help.
./levels[level/teams/team/name = 'Dallas Stars']