<?xml version="1.0" encoding="UTF-8"?>
<Emp:Employee xmlns:Emp="http://Emp.com">
<Emp:EmpName>XYZ</Emp:EmpName>
<Emp:EmpAddres>AAAA</Emp:EmpAddres>
<Det:EmpDetails xmlns:Det="http://Det.com">
<Det:EmpDesignation>SE</Det:EmpDesignation>
<Det:EmpExperience>4</Det:EmpExperience>
</Det:EmpDetails>
</Emp:Employee>
I am just trying to copy all the elements including the namespace but without <Det:EmpExperience>4</Det:EmpExperience>
so the final output should be :
<?xml version="1.0" encoding="UTF-8"?>
<Emp:Employee xmlns:Emp="http://Emp.com">
<Emp:EmpName>XYZ</Emp:EmpName>
<Emp:EmpAddres>AAAA</Emp:EmpAddres>
<Det:EmpDetails xmlns:Det="http://Det.com">
<Det:EmpDesignation>SE</Det:EmpDesignation>
</Det:EmpDetails>
</Emp:Employee>
I used
<xsl:template match='/'>
<xsl:copy-of select='@*[not(Det:EmpExperience)]'/>
</xsl:template>
its not working :-( ... any solution for this plz.
how to remove only <Det:EmpExperience>
element and copy rest of the elements including namespace ?