0
votes

Have an XML that I need to validate using XSD, the XSD includes a global reference to an element using "dateTime" type, the element on my XML will have a "date" type instead, so I was hoping I could override the Global XSD element reference with a local one.

on global:

<xs:element name="dt" type="xs:dateTime"/>

xml file:

<dt>2011-11-28</dt>

on local override like this:

<xs:element name="dt" type="xs:date"/>
1

1 Answers

0
votes

The XSD you have is a definition of a XML instance. If you want to use it for validation then your instance must conform to all aspects of the definition without exception. So without changing your XSD definition I don't see how you can do this.