Question Remove nodes from XML string

christopher3683

New member
Joined
Aug 13, 2013
Messages
4
Programming Experience
5-10
Hi,

I have a xml string like this

<?xml version='1.0' standalone='yes'?><NewDataSet><Table1><IP>100.100.178.116</IP><DBName>16Summus</DBName><DB_Status>Down</DB_Status></Table1></NewDataSet>
<?xml version='1.0' standalone='yes'?><NewDataSet><Table1><IP>100.100.178.124</IP><DBName>i-elic</DBName><DB_Status>Down</DB_Status></Table1></NewDataSet>
<?xml version='1.0' standalone='yes'?><NewDataSet><Table1><IP>100.100.178.20</IP><DBName>iwatch</DBName><DB_Status>UP</DB_Status></Table1></NewDataSet>
<?xml version='1.0' standalone='yes'?><NewDataSet><Table1><IP>100.100.193.315</IP><DBName>iWatch_local</DBName><DB_Status>Down</DB_Status></Table1></NewDataSet>

from this xml string i want to create xml file like this

<?xml version='1.0' standalone='yes'?>
<NewDataSet>
<Table1><IP>100.100. 178.16</IP><DBName>16Summus</DBName><DB_Status>Down</DB_Status></Table1>
<Table1><IP>100.100. 178.124</IP><DBName>i-elic</DBName><DB_Status>Down</DB_Status></Table1>
<Table1><IP>100.100. 178.16</IP><DBName>iwatch</DBName><DB_Status>UP</DB_Status></Table1>
<Table1><IP>100.100. 178.11</IP><DBName>iWatch_local</DBName><DB_Status>Down</DB_Status></Table1>
</NewDataSet>
 
Last edited:
Top Bottom