Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Defining Date Format in XSD Not Working!

Status
Not open for further replies.

jasonp45

Programmer
Aug 23, 2001
212
US
I have an XML file which has dates in YYYYMMDD format.

I am trying to import this into Access 2003.

I have a valid XSD which will allow my data to import...however, I can only get the dates to come through as strings.

I am trying to insert dashes with a pattern:
<xs:element name="Exp_Date" type="dateType"/>
<xs:simpleType name="dateType">
<xs:restriction base="xs:string">
<xs:pattern value="[1,2][0-9]{3}-[0-9]{2}-[0-9]{2}"/>
</xs:restriction>
</xs:simpleType>

But it isn't working. How can I get my XSD to transform YYYYMMDD dates to valid XML dates so Access will import them properly?

Thanks!
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top