[Mono-bugs] [Bug 60742][Min] Changed - DataSet Xml Schema Inference bug on MONO

bugzilla-daemon@bugzilla.ximian.com bugzilla-daemon@bugzilla.ximian.com
Sat, 26 Jun 2004 04:41:03 -0400 (EDT)


Please do not reply to this email- if you want to comment on the bug, go to the
URL shown below and enter your comments there.

Changed by davidandrewtaylor@hotmail.com.

http://bugzilla.ximian.com/show_bug.cgi?id=60742

--- shadow/60742	2004-06-25 17:25:07.000000000 -0400
+++ shadow/60742.tmp.20114	2004-06-26 04:41:03.000000000 -0400
@@ -10,13 +10,12 @@
 Component: Sys.Data
 AssignedTo: mono-bugs@ximian.com                            
 ReportedBy: davidandrewtaylor@hotmail.com               
 QAContact: mono-bugs@ximian.com
 TargetMilestone: ---
 URL: 
-Cc: 
 Summary: DataSet Xml Schema Inference bug on MONO
 
 Description of Problem:
 (Note: I tested this with the latest build of MONO from CVS.)
 
 MONO's DataSet has always been reasonably flaky when it comes to loading 
@@ -83,6 +82,56 @@
 http://msdn.microsoft.com/library/default.asp?url=/library/en-us/cpguide/html/cpconinferencelimitations.asp
 
 
 For example, ReadXmlSchema() is more important and I actually did
 standalone testing and found that MS.NET is buggy enough to handle
 post schema compilation information.
+
+------- Additional Comments From davidandrewtaylor@hotmail.com  2004-06-26 04:41 -------
+Hi Atsushi.  Sorry for the brevity of my initial post, but I can 
+help more now because I have spent some more time today analysing 
+the exact problem.
+
+It appear this bug occurs when an element is mapped to a table and 
+then later in the xml document the same element appear inside 
+another node.  Please look at this XML:
+
+<data>
+
+  <innernode>
+    <value>Hello</value>
+  </innernode>
+
+  <outernode name="outernode">
+    <innernode>
+      <value>Hello</value>
+    </innernode>
+  </outernode>
+
+</data>
+
+The error message is "Child column was not found :outernode_Id".  So 
+obviously when the first <innernode> is read, the schema inferrer 
+doesn't need to create an outernode_Id column; but then when the 
+second node is processed your code is "looking" for the outernode_Id 
+column when it really needs to create it!
+
+Note: Of course that if I changed the order of the XML the bug will 
+not appear in MONO because the outernode_Id column is created the 
+first time...So this works fine in MONO.
+
+<data>
+
+  <outernode name="outernode">
+    <innernode>
+      <value>Hello</value>
+    </innernode>
+  </outernode>
+
+  <innernode>
+    <value>Hello</value>
+  </innernode>
+
+</data>
+
+I hope that helps you debug the issue!
+