September 28, 2019 at 11:02 pm
Hi,
I have to compare XML contents in column A in Table A in Database A with XML contents in column B in Table B in Database B.
Basically I want to see if the contents of XML files equal or different.
Can please provide me a sample SQL Query to achieve this ?
Thanks,
September 28, 2019 at 11:16 pm
Can you provide sample DDL and data, please? In the form of INSERT statements.
September 30, 2019 at 3:00 pm
You also need to specify what you mean by "equal or different". XML files can contain exactly the same information, but have a slightly different layout. Are they equal because they have the same information or are they different, because they have a different layout. For example
<person>
<first>James</first>
<last>Bond</last>
</person>
and
<person>
<last>Bond</last>
<first>James</first>
</person>
are semantically equal, but have different layouts.
Also, XML is case-sensitive. Does that matter for your purposes?
Drew
J. Drew Allen
Business Intelligence Analyst
Philadelphia, PA
September 30, 2019 at 3:56 pm
May be I will first try comparing one field value, which I know it should be there if the are for same transaction.
Please advise.
September 30, 2019 at 4:13 pm
script to compare one field value in two xml files.
Viewing 7 posts - 1 through 7 (of 7 total)
You must be logged in to reply to this topic. Login to reply