Ask the Expert

Trying to define an XML Schema for a flat file...

I am trying to define an XML Schema for a flat file. One of the fields is a date in the format mm/dd/yyyy. Is there some where that I can go to find a definition of the SimpleType to validate such a field?

    Requires Free Membership to View

Appendix D of part II of the W3C Schema specification details the built-in types for handling dates ( I would urge you to use the built-in types rather than create your own where possible.

This is especially true in the case of dates because, although it is theoretically possible to validate dates (taking account of leap years etc.) using regular expressions, such as can be used with SimpleType, can get very complicated. (

This was first published in December 2001

There are Comments. Add yours.

TIP: Want to include a code block in your comment? Use <pre> or <code> tags around the desired text. Ex: <code>insert code</code>

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy
Sort by: OldestNewest

Forgot Password?

No problem! Submit your e-mail address below. We'll send you an email containing your password.

Your password has been sent to: