[Mono-bugs] [Bug 78985][Maj] New - XML Schema key constraints

bugzilla-daemon at bugzilla.ximian.com bugzilla-daemon at bugzilla.ximian.com
Mon Jul 31 22:07:35 EDT 2006

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 mark_cox at tpg.com.au.


--- shadow/78985	2006-07-31 22:07:35.000000000 -0400
+++ shadow/78985.tmp.1936	2006-07-31 22:07:35.000000000 -0400
@@ -0,0 +1,60 @@
+Bug#: 78985
+Product: Mono: Class Libraries
+Version: unspecified
+OS Details: 
+Status: NEW   
+Priority: Major
+Component: Sys.XML
+AssignedTo: atsushi at ximian.com                            
+ReportedBy: mark_cox at tpg.com.au               
+QAContact: mono-bugs at ximian.com
+TargetMilestone: ---
+Summary: XML Schema key constraints
+The mono-xmltool Schema validator fails to validate an XML Document.
+The XML document is as follows:
+<root xmlns=.....>
+   <scoreGroup key="test">
+      <score key="example">An example</score>
+   </scoreGroup>
+   <scoreGroup key="test2">
+      <score key="example2">An example 2</score>
+   </scoreGroup>
+The key attribute for the scoreGroup element must be unique.
+The key attribute for the score element must be unique within the score group.
+mono-xmltool --validate-xsd schema.xsd xmlfile.xml outputs
+XmlSchema error: The key value was already found. At line 3, position 14.
+I: file:///C:/tmp/xmltest/xml/XMLFile2.xml . Line 4, Position 10. Related
+ item SourceUri: file:///C:/tmp/xmltest/xml/XMLSchema2.xsd, Line 29,
+Position 4.
+If I change one of the attributes from key to something else, validation
+passes. Tests for uniqueness confirm that the validator is in fact catching
+ non unique keys.
+Visual Studio 2003 validates both versions of the xml and schema documents
+with no problems.
+How often does this happen? 
+Everytime on MacOSX and Windows.
+Additional Information:
+I have the schema and xml files if required.
+Mono JIT compiler version, (C) 2002-2006 Novell, Inc and
+Contributors. www.mono-project.com
+	TLS:           normal
+	GC:            Included Boehm (with typed GC)
+	SIGSEGV:       normal
+	Disabled:      none

More information about the mono-bugs mailing list