I am new to XML. I need write a XML parser to get the difference between two XML files and output of the difference should be in XML format.
For Example :
File1.xml
<UserInfo>
<DivisionInfo>
<Name>ron</Name>
<ID>2345</ID>
<Name>amid</Name>
<ID>4563</ID>
</DivisionInfo>
</UserInfo>
File2.xml
<UserInfo>
<DivisionInfo>
<Name>ron</Name>
<ID>1234</ID>
<Name>amid</Name>
<ID>4563</ID>
</DivisionInfo>
</UserInfo>
Output :
<UserInfo>
<DivisionInfo>
<Name>ron</Name>
<ID>1234</ID>
</DivisionInfo>
</UserInfo>
I need the full tree structure of difference in XML. Because i will 10000 set user list every day. I want to compare the the latest xml file with the previous day xml file and update the new information. Is there any XML library is provided? or we should write our own parser?
thanks in advance.
Aucun commentaire:
Enregistrer un commentaire