What information do you have so you know what to add to file one? For instance, will you have a group number and a list of book names? How do you know which nodes to remove? Whole groups or just individual books?
You cannot do this with just XPath query, this can only locate nodes, you will either need to do an XSLT transformation or use the DOM to append and remove nodes.
Joe (MVP - xml)
|