OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.

 


Help: OASIS Mailing Lists Help | MarkMail Help

 


 

   Re: Why XML data typing is hard

[ Lists Home | Date Index | Thread Index ]
  • From: Joel Bender <joel@spooky.emcs.cornell.edu>
  • To: xml-dev@ic.ac.uk
  • Date: Tue, 1 Dec 1998 15:18:18 -0500

G. Ken Holman wrote:

>  In Canada, valid expressions of currency numbers are $1.47 or
>  1,47$ based on where you are.

I was under the impression that there was some standard patterns/parsers
for this stuff being designed.  So:

	<value xml:type="currency">1.5</value>

Gets parsed as if it was specified as:

	<value xml:type="currency" xml:country="Canada.English">1.5</value>

(No offense intended to those in French Canada that want to make it their
own country.)

>  I gather from Michael S-McQ in a presentation in Chicago that
>  the regular expression for a valid date (taking into account
>  days of the month and leap years) is 4801 characters long.

Probably an interesting effort, what we used to call a "weekend and a case
of beer" project.  I'm sure that another notation could be found that would
reduce this significantly, roll a little grep and JavaScript together or
something :-).

This discussion is important to me because my application to test protocol
conformance needs to suck in an XML description of an "implementation under
test" and translate the '1.5' into an IEEE float that will appear on a
wire.  My app will need at least some guidence on accepting '1,5' and/or
'1.5' and/or the Japanese Unicode string that means the same thing.  The
good news for me is that I really only need to deal with SQL data types.


Joel

xml-dev: A list for W3C XML Developers. To post, mailto:xml-dev@ic.ac.uk
Archived as: http://www.lists.ic.ac.uk/hypermail/xml-dev/
To (un)subscribe, mailto:majordomo@ic.ac.uk the following message;
(un)subscribe xml-dev
To subscribe to the digests, mailto:majordomo@ic.ac.uk the following message;
subscribe xml-dev-digest
List coordinator, Henry Rzepa (mailto:rzepa@ic.ac.uk)





 

News | XML in Industry | Calendar | XML Registry
Marketplace | Resources | MyXML.org | Sponsors | Privacy Statement

Copyright 2001 XML.org. This site is hosted by OASIS