The Input Xml is Below.
<?xml version="1.0"?>
<TABLE tableid="PLSW">
<CELL rowmerged="T" rowspan="2" >
<Para >11<refint>AA</refint>
<ext>BB</ext>
</Para>
</CELL>
<CELL rowmerged="T" rowspan="2" >
<Para >12<ext>BB</ext></Para>
</CELL>
<CELL rowmerged="F" rowspan="1" >
<Para >13<refint>CC</refint></Para>
</CELL>
</TABLE>
I need XPATH for the above Input XML.If any of one <Para>contains refint with some other tag(<ext>) or it contains only some other tags (ex:(<ext>),then it should change the taleid="PLSW" to tableid="ADHOC".can you please tell some ideas to write XPATH for the Scanario.
Note:I am new to XPATH.
My output will be:
<?xml version="1.0"?>
<TABLE tableid="ADHOC">
<CELL rowmerged="T" rowspan="2" >
<Para >11<refint>AA</refint>
<ext>BB</ext>
</Para>
</CELL>
<CELL rowmerged="T" rowspan="2" >
<Para >12<ext>BB</ext></Para>
</CELL>
<CELL rowmerged="F" rowspan="1" >
<Para >13<refint>CC</refint></Para>
</CELL>
</TABLE>