[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

Re: Testing 2 XML documents for equality - a solution

Subject: Re: Testing 2 XML documents for equality - a solution
From: Mukul Gandhi <mukul_gandhi@xxxxxxxxx>
Date: Wed, 30 Mar 2005 18:36:23 -0800 (PST)
gandhi documents
Hi Dimitre,
  Please read my response below your comments..

> Two XML documents will be considered
> equal
> > if all their nodes are identical(i.e. element,
> text,
> > attribute, namespace etc).
> 
> This is not a precise definition of "document
> equality".

oh! Please don't take my definition of "document
equality" from a pure mathematical view point. Its not
as in "is 2=3 ?" . Did you got that impression from my
definition? I meant that 2 XML documents will be equal
if they have identical node structure. i.e. abstract
structure of 2 documents should be identical and not
at byte stream level(this was not my goal).

Another definition for the problem I am trying to
solve would be, XML documents will be same if they
*look similar* in a text editor like nodepad..

so, document
<x>
 <a i="1">
</x>
will be equivalent to 
<x>
 <a i="1">
</x>

but not to
<x>
 <a i="2">
</x>

Yet another definition that applies to my problem
would be ! 2 documents will be equal if they produce
same output by an XSLT identity transform..

The "same, equivalent" are better words than "equal"
to the problem I was trying to solve..

> Trying to solve an imprecisely formulated problem is
> not a
> well-founded and understood activity.

True!

> Generally, there is no solution to incorrectly
> formulated problems,
> therefore lets return to solving real problems.
> 

:) Of course

Regards,
Mukul

> Cheers,
> Dimitre Novatchev




		
__________________________________ 
Do you Yahoo!? 
Yahoo! Small Business - Try our new resources site!
http://smallbusiness.yahoo.com/resources/ 

Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.