473,385 Members | 1,492 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

ReadXML giving different results on different PCs

RM
I am using DataSet's .ReadXml() method to parse an XML file that has an
inline schema and Im getting "different" results on various machines
using the same myDataSet.ReadXml("myExample.xml").

Out of 5 test machines, my results are as follows.

1 Windows 2000 Server and
2 Windows XP Professional PC's
that parses the XML, builds 2 tables with appropriate format columns
(string, int, etc) and populates the tables with rows of data as expected.

1 Windows 2000 Server and
1 Windows XP Professional PC
that parses the XML, builds 2 tables with appropriate format colums
(string, int, etc) but does NOT populate the tables with any data.

I cannot seem to determine what the difference between the setups is
that's causing this. It's clearly not the OS. All machines have .NET 1.1
on them, on one of the non-working (no rows) machines I installed MDAC
2.8 and the latest MSXML parser, to no avail.

Attaching my XML for examination, it may not be very correct XML, Im not
sure, but I find it wierd either way that 5 machines build tables out of
it, but only 3 of the 5 actually populate the table with rows. Always
running the same EXE that calls the same ReadXml method on the same XML
file.

Thank you for your time :)


Nov 12 '05 #1
1 1732
RM
I've fixed the problem to some extent, I found a solid schema validator
and it helped me isolated a couple of bugs in my XML, after fixing those
the XML loads fine in any of the 5 test machines.

I guess Im still bothered by "what is different" between the machines
where the attached XML would load into table rows on some, but not on
others. Im itching to know what is causing the difference between
machines when its clearly not the version of .NET or the OS.

RM wrote:
I am using DataSet's .ReadXml() method to parse an XML file that has an
inline schema and Im getting "different" results on various machines
using the same myDataSet.ReadXml("myExample.xml").

Out of 5 test machines, my results are as follows.

1 Windows 2000 Server and
2 Windows XP Professional PC's
that parses the XML, builds 2 tables with appropriate format columns
(string, int, etc) and populates the tables with rows of data as expected.

1 Windows 2000 Server and
1 Windows XP Professional PC
that parses the XML, builds 2 tables with appropriate format colums
(string, int, etc) but does NOT populate the tables with any data.

I cannot seem to determine what the difference between the setups is
that's causing this. It's clearly not the OS. All machines have .NET 1.1
on them, on one of the non-working (no rows) machines I installed MDAC
2.8 and the latest MSXML parser, to no avail.

Attaching my XML for examination, it may not be very correct XML, Im not
sure, but I find it wierd either way that 5 machines build tables out of
it, but only 3 of the 5 actually populate the table with rows. Always
running the same EXE that calls the same ReadXml method on the same XML
file.

Thank you for your time :)


------------------------------------------------------------------------

<?xml version="1.0"?>

<root>
<xs:schema xmlns:xs='http://www.w3.org/2001/XMLSchema' xmlns='xsdConfig' targetNamespace='xsdConfig'>
<xs:element name='Config'>
<xs:complexType>
<xs:sequence>
<xs:element name="ObServerConfig">
<xs:complexType>
<xs:sequence>
<xs:element name='mailServerIp' type='xs:string' />
<xs:element name='mailFrom' type='xs:string' />
<xs:element name='timeOut' type='xs:integer' />
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:element name="server">
<xs:complexType>
<xs:sequence>
<xs:element name='url' type='xs:string' />
<xs:element name='email' type='xs:string' />
<xs:element name='enabled' type='xs:boolean' />
<xs:element name='notify'>
<xs:simpleType>
<xs:restriction base="xs:string">
<xs:pattern value="up|down|both" />
</xs:restriction>
</xs:simpleType>
</xs:element>
</xs:sequence>
</xs:complexType>
</xs:element>
</xs:sequence>
</xs:complexType>
</xs:element>
</xs:schema>
<a:Config xmlns:a='xsdConfig'>
<a:ObServerConfig>
<a:mailServerIp>127.0.0.1</a:mailServerIp>
<a:mailFrom>no@one.com</a:mailFrom>
<a:timeOut>5</a:timeOut>
</a:ObServerConfig>
<a:server>
<a:url>http://www.cnn.com</a:url>
<a:email>no@one.com</a:email>
<a:enabled>true</a:enabled>
<a:notify>down</a:notify>
</a:server>
<a:server>
<a:url>http://www.yahoo.com</a:url>
<a:email>no@one.com</a:email>
<a:enabled>false</a:enabled>
<a:notify>down</a:notify>
</a:server>
</a:Config>
</root>

Nov 12 '05 #2

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

Similar topics

11
by: DraguVaso | last post by:
Hi, I should use XML to synchronize the data from different (VB.NET) applications, and I was just wondering which Overloads of these functions ( ReadXmlSchema, ReadXml and WriteXml) goes the...
0
by: RM | last post by:
I have a simple XML file, the contents of which are below. I have validated this XML file with Microsofts online validator and it validates successfully. I .ReadXml() this data into a DataSet in...
8
by: Nikhilesh Mehendale | last post by:
I have written a web service in C#, .NET 1.1 which reads a XML file into a dataset. This is just a plain XML file. First I use the Dataset.ReadXmlScheme function and pass the XML file to it. Then...
2
by: bfrasca | last post by:
I have a well-formed XML file that I am trying to load into a dataset using the ReadXML method. It keeps telling me that "there are multiple root elements". I can view the data using XML Designer...
3
by: Steve | last post by:
I've run across an issue that I'm trying to work around. I take that back, I have a work around but I'm looking to see if anyone has a fix for it. The issue is that when loading a Boolean into a...
4
by: Prasad Dannani | last post by:
Hi, When reading XML Files from .Net we are facing different different issues. like "The data at the root level is invalid. Line 1, position 1" and some more with extra spaces at the beginning...
1
by: Ryan Ramsey | last post by:
I currently have this code: string filePath = "c:\\results.xml" PlayersDataSet.ReadXml(filePath); and it works fine, it reads the local xml file into a dataset... If I change the filePath to...
10
by: webmaster | last post by:
Getting error: Illegal characters in path what's wrong with this? string xmlSR = "<XmlDS><table1><phone>Value1</phone><name>jake</name></table1></XmlDS>"; myDataSet.ReadXml(xmlSR,...
0
by: Arto Viitanen | last post by:
I am using WriteXML/ReadXml pair to save DataSet for later use. DataSet is built by reading textfiles and storing their data to different DataTables. Each file contains several complex values, that...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...

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.