RE: Date

Martin:
The schema for your format is not difficult to write but before that
The CCYYMMDD format should allow an optional negative sign and five
characters in the CCYY format.

To write the schema, you would first create a simple type that restricts
"string" with a pattern corresponding to the format discussed above.
This pattern should, as far as possible only allow legal date values
i.e. the first D in the DD field should allow only 0,1,2 or 3.  The
bigger problem is whether you want to disallow February 30 and November
31 with a pattern.

All the best, Ashok 
===========================================================
Ashok Malhotra              <mailto: ashokma@microsoft.com> 
Microsoft Corporation
212 Hessian Hills Road
Croton-On-Hudson, NY 10520 USA 
Redmond: 425-703-9462                New York: 914-271-6477 



-----Original Message-----
From: Martin Duerst [mailto:duerst@w3.org] 
Sent: Tuesday, July 03, 2001 5:01 AM
To: Chelkowski, Tadeusz; xmlschema-dev@w3.org
Subject: Re: Date

Hello Tadeusz,

The unique format was chosen to make it very easy to exchange data.
If you need to markup some actual text in another format, or you
otherwise want to keep another format, I suggest you use something
like

<date value='CCYY-MM-DD'>CCYYMMDD</date>

Regards,   Martin.

P.S.: If somebody can write a schema for the above fragment,
       we'll probably add it (in one form or another) to the
       type library.

At 11:11 01/07/03 +0200, Chelkowski, Tadeusz wrote:
>Hello!
>How to declare an element xsd:date but default set for separators are
dashes
>(-) i would like to have date in pure CCYYMMDD format not in
CCYY-MM-DD.
>Thank you
>
>Regards
>Tadeusz Chelkowski, Software AG Poland

Received on Wednesday, 4 July 2001 09:24:15 UTC