XML 1.0 came with a basic set of data types mostly useful for describing documents and their contents. Some XML schema dialects like XDR and SOX provide a larger set of data types that can be used to constrain element and attribute content to more traditional data categories. Data types in a schema allow you to specify not only that an element or attribute should appear at a particular location in the document structure, but what kind of information is contained in that element or attribute - text, numbers, currency, times, dates, and more.
Data typing isn't necessary for all kinds of schemas, though it can be useful in a wide variety of situations. Schemas that describe purely textual information - memos, fiction, articles - can often do without them. Sometimes information that can be easily typed will also appear in these documents (like the date in a memo), and a data type can be used to highlight that information, though it isn't required. In other situations, like exchanges between databases and representations of internal software object structures, data types provide crucial information that can tell a program what to expect.
When you use XML Instance to apply a schema, any data typing information it may contain has already been collected for you.
Copyright 2000 Extensibility, Inc.
Suite 250, 200 Franklin Street, Chapel Hill, North Carolina 27516