473,563 Members | 2,797 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Comparing XML Files

I'm asking for ideas how to compare XML files. The files are schema-based
"Test Logs". They will be generated by several different machines, and the
longer files could be 1000 lines.

Some differences are ok:
<computer>SPITF IRE</computer>
vs
<computer>ODI N</computer>
However most differences are NOT ok:
<results>Passed </results>
vs
<results>Failed </results>
Additionally, some children may not always be in the same order, but this is
ok.
I'm wondering if the test logs could be imported into Excel or Access and
(more easily) analyized. I hope is isn't a from-scratch C# or VB .NET
application.

Thoughts?

Thanks.

-- Mark
Nov 16 '05 #1
3 5349
Mark Jerde wrote:
I'm asking for ideas how to compare XML files. The files are schema-based
"Test Logs". They will be generated by several different machines, and the
longer files could be 1000 lines.

Some differences are ok:
<computer>SPITF IRE</computer>
vs
<computer>ODI N</computer>
However most differences are NOT ok:
<results>Passed </results>
vs
<results>Failed </results>
Additionally, some children may not always be in the same order, but this is
ok.
I'm wondering if the test logs could be imported into Excel or Access and
(more easily) analyized. I hope is isn't a from-scratch C# or VB .NET
application.

Thoughts?

Thanks.

-- Mark

Mark,

Sometimes, it's easier to write a little application to do the
comparison. .Net offers a rich library to parse the Xml files. You
surely could import it into Excel or Access , but even in that way, I
would suggest to write some scripts. Imagine if you have to do it a
thousand times, wouldn't it be nicer to write a simple application, and
double click it instead of going to File ->import -> ....

My two cents.

Jianwei
Nov 16 '05 #2
Mark,

Go to gotdotnet.com and look under tools at XML diff. It can easily be used
to get a set of difference information between 2 XML files.

HTH,

Matt
"Mark Jerde" <ma********@ver izon.no.spam.ne t> wrote in message
news:u4******** ******@TK2MSFTN GP09.phx.gbl...
I'm asking for ideas how to compare XML files. The files are schema-based
"Test Logs". They will be generated by several different machines, and the longer files could be 1000 lines.

Some differences are ok:
<computer>SPITF IRE</computer>
vs
<computer>ODI N</computer>
However most differences are NOT ok:
<results>Passed </results>
vs
<results>Failed </results>
Additionally, some children may not always be in the same order, but this is ok.
I'm wondering if the test logs could be imported into Excel or Access and
(more easily) analyized. I hope is isn't a from-scratch C# or VB .NET
application.

Thoughts?

Thanks.

-- Mark

Nov 16 '05 #3
Thanks for the input, John & Matt.

I just ran the first complete test. The XML file is 4078 lines long. When
more tests are added that should grow to 6000 lines. I need to figure out
automation. ;-)

-- Mark

John Sun wrote:
Mark Jerde wrote:
I'm asking for ideas how to compare XML files. The files are
schema-based "Test Logs". They will be generated by several
different machines, and the longer files could be 1000 lines.

Some differences are ok:
<computer>SPITF IRE</computer>
vs
<computer>ODI N</computer>
However most differences are NOT ok:
<results>Passed </results>
vs
<results>Failed </results>
Additionally, some children may not always be in the same order, but
this is ok.
I'm wondering if the test logs could be imported into Excel or
Access and (more easily) analyized. I hope is isn't a from-scratch
C# or VB .NET application.

Thoughts?

Thanks.

-- Mark

Mark,

Sometimes, it's easier to write a little application to do the
comparison. .Net offers a rich library to parse the Xml files. You
surely could import it into Excel or Access , but even in that way, I
would suggest to write some scripts. Imagine if you have to do it a
thousand times, wouldn't it be nicer to write a simple application,
and double click it instead of going to File ->import -> ....

My two cents.

Jianwei

Nov 16 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

11
1995
by: Dan Stromberg | last post by:
We will soon have 3 copies, for testing purposes, of what should be about 4.5 terrabytes of data. Rather than cmp'ing twice, to verify data integrity, I was thinking we could speed up the comparison a bit, by using a python script that does 3 reads, instead of 4 reads, per disk block - with a sufficiently large blocksize, of course. My...
8
6713
by: Corno | last post by:
Hi all, Does anybody know a command line tool (linux or windows) that can compare 2 XML files. There's only 1 extra requirement that makes it a bit more complicated: the order of attributes or elements within an element is of no importance, and so the tool should still report that 2 XML files are equal even though the order is different. ...
18
2022
by: HerrLucifer | last post by:
I am each day becoming more and more addicted to the new .Net framework because of its cool RAD facilities. However, performance and speed is extremely important for my application development. I have done many various tests to compare the performance speed of applications written in C++ 6.0 V.S. the same ones in VB.Net or VC#.Net . The...
4
5526
by: ddd | last post by:
I am trying to build a diff tool that allows me to compare two HTML files. I am looking for resources on how to achive this. The main problem is that I do not want to simply highlight the line of code where the change happened, but rather the word/text that changed. Example say the html file contains a table with three cells/one row, and all...
5
1508
by: Peteroid | last post by:
I realize this might not be the correct newsgroup, but since I have a general question I need answering in the context of doing a managed VC++.NET Managed application, this is as good a place as any to get the ball rolling. Where is the appropriate place to ask the following question: Is there any way to compare two text files to see if they...
0
2383
by: richardkreidl | last post by:
I have the following hash script that I use to compare two text files. 'Class Public Class FileComparison Public Class FileComparisonException Public Enum ExceptionType U 'Unknown A 'Add D 'Delete
3
4269
by: s99999999s2003 | last post by:
hi i wrote some code to compare 2 files. One is the base file, the other file i got from somewhere. I need to compare this file against the base, eg base file abc def ghi eg another file
3
3166
by: system55 | last post by:
are there any commands that can compare two files? Comparing in the sense that the two files are alike... Because I wrote a program that makes a backup file of another file... Just want to know if the files are the same... hope somebody can help me....
0
1083
by: Gabriel Genellina | last post by:
En Thu, 15 May 2008 06:02:29 -0300, Beema shafreen <beema.shafreen@gmail.comescribió: *three* columns? You menction only two of them. Do you have to syncrhonize both listings? That is, search for matches that are not in the same line? Or just compare line by line? In the first case, the difflib module may help:
1
2324
by: Avi1 | last post by:
Hi, I got the code (from the internet)for comparing two files and showing the difference in contents.Now,I tried the same code for two files written in japanese language(kanji).If I save the two japanese .txt files in ANSI format,it works fine,but, if I save them in formats like 'UTF-8','unicode','unicode bigendian',it doesn't show the...
0
7665
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main...
0
8106
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that...
0
7950
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the...
0
6255
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then...
0
5213
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert...
0
3643
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in...
0
3626
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
2082
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
0
924
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.