I have an xml with below structure which is stored as a clob column in a table.
I have to update the Zipcode and City fields to 1000 and Abcd wherever the existing node contains a Zipcode 95813.
There can be multiple address node with same city and Zipcode.
Please help me, Thanks in advance.
<Employee>
<Name>John</Name>
<Age>26</Age>
<Addresses>
<Address>
<Street>Street1</Street>
<City>Sacramento</City>
<ZipCode>95813</ZipCode>
</Address>
<Address>
<Street>Street2</Street>
<City>Los Angeles</City>
<ZipCode>95300</ZipCode>
</Address>
</Addresses>
</Employee>
expected output
<Employee>
<Name>John</Name>
<Age>26</Age>
<Addresses>
<Address>
<Street>Street1</Street>
<City>Abcd</City>
<ZipCode>1000</ZipCode>
</Address>
<Address>
<Street>Street2</Street>
<City>Los Angeles</City>
<ZipCode>95300</ZipCode>
</Address>
</Addresses>
</Employee>
I have already tried updatexml function but didn’t find an option to update specific nodes based on condition in updatexml