[Home] [By Thread] [By Date] [Recent Entries]
Etheridge, Stephen wrote:
I am trying to compare two xml documents of the same format. I have successfully transformed the documents to include a field called ItemKey which includes a unique key (comprised of four other elements). I am now trying to match and compare elements based on that key value. First of all, in a pattern like the match attribute you never need to start with "//", match="ItemKey" is enough, doing match="//ItemKey" does not gain anything. And match="//ItemKey" use="//ItemKey" looks very odd, usually the "use" attribute selects an attribute (e.g. use="@foo") or a child element (e.g. use="bar") or the node itself (e.g. use=".") but putting use="//ItemKey" looks wrong, that way you "key" any "ItemKey" element on any "ItemKey" element in the document. -- Martin Honnen http://msmvps.com/blogs/martin_honnen/
|

Cart



