Solved

XMLXQueryExtractor extract Attribute


Userlevel 1
Badge +15

I have the following XML:

<?xml version="1.0" encoding="UTF-8"?>
<MyProblem>
<Maat Name="MyName1" Description="LetsDoIt">
<Status_Maat Value="Open"/>
</Maat>
<Maat Name="MyName2">
<Status_Maat Value="Open"/>
</Maat>
<Procon Description="FinalCheck"/>
<Precon Description="StopAndCheck"/>
<Maat Name="MyName3" Description="LetsDoNothing">
<Status_Maat Value="Open"/>
</Maat>
</MyProblem>

I can extract the Maat with XMLXQueryExtrator by the following expression:

/MyProblem/Maat

 

Notepad++ XMLTools says the path to the Description is 

/MyProblem/Maat/@Description 

but this gives an error. And no results.

 

What am I doing wrong?

icon

Best answer by ebygomm 4 April 2023, 14:49

View original

2 replies

Userlevel 1
Badge +10

Try

/MyProblem/Maat/@Description/string()

 

Userlevel 1
Badge +15

Thanks, that worked.

Reply