[
Lists Home |
Date Index |
Thread Index
]
6/11/2002 10:44:22 AM, "Simon St.Laurent" <simonstl@simonstl.com> wrote:
>At 07:
>>Data entry is a user interface issue. There are plenty of applications
>>out there that allow you to type in "June 11, 2002", then store it as,
>>e.g., 2002-06-11. I don't think anyone is saying end users should be
>>subject to such rigid constraints, or if they are they should be slapped
>>silly.
>
>That's a nice way to look at it if you come to XML from the expectation of
>a GUI editor or forms-based system between the user and the markup.
>
>It's downright nonsensical if you come to XML from a more hands-on approach
Hmmmmm ... ya pays yer money and ya takes yer choice: You can:
- Have some input-time code (or post-input cleanup code) that normalizes values so that they can be
effectively processed as strings, such as converting natural language, locale-specific dates into ISO (or
some other) format that allows them to be sorted and compared as strings ...
- Use a schema, schema-processor, and schema-aware sorting/comparison tools such as XPath 2 or XQuery to
process the XML as typed values rather than strings ...
- Live with the fact that 1.00 != 1, and 20020611 != June 11, 2002, ad nauseum.
For my money, normalizing the values can solve many of the problems that strongly typed schema languages are
supposed to solve, but often more simply/cheaply/portably/etc.
<RagOnSimon> You don't like schemas, you don't like GUIs, you don't like bloated applications ... how DO you
handle these problems? </RagOnSimon> :~)
|