W3C home > Mailing lists > Public > xmlschema-dev@w3.org > July 2001

RE: Date

From: Ashok Malhotra <ashokma@microsoft.com>
Date: Wed, 4 Jul 2001 07:01:41 -0700
Message-ID: <9D884881F5E1F24FB845967851720FC31D1B35@red-msg-12.redmond.corp.microsoft.com>
To: "Chelkowski, Tadeusz" <Tadeusz.Chelkowski@softwareag.com>, <xmlschema-dev@w3.org>
OK.  Here is a Schema for the element suggested by Martin

<xsd:element name = 'myDate'>
      <xsd:restriction base='xsd:string'>
    <xsd:attribute name= 'value' type='xsd:date'>

All the best, Ashok 

-----Original Message-----
From: Chelkowski, Tadeusz [mailto:Tadeusz.Chelkowski@softwareag.com] 
Sent: Wednesday, July 04, 2001 6:40 AM
To: xmlschema-dev@w3.org
Subject: RE: Date


Yes'Ive created the

but to check all 31-30 month or febuary  thats more complicated thats
why i
would like to use standard xsd:dated format and use it with CCYYMMDD
instead of CCYY-MM-DD.

Tadeusz Chelkowski, Software AG Poland

-----Original Message-----
From: Ashok Malhotra [mailto:ashokma@microsoft.com]
Sent: Wednesday, July 04, 2001 2:58 PM
To: Martin Duerst; Chelkowski, Tadeusz; xmlschema-dev@w3.org
Subject: RE: Date

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

<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:
>How to declare an element xsd:date but default set for separators are
>(-) i would like to have date in pure CCYYMMDD format not in
>Thank you
>Tadeusz Chelkowski, Software AG Poland
Received on Wednesday, 4 July 2001 10:03:36 UTC

This archive was generated by hypermail 2.3.1 : Wednesday, 7 January 2015 14:55:52 UTC