Sign In/My Account | View Cart  
advertisement

Article:
 Schema Scuffles and Namespace Pains
Subject: Before I run back to DTDs ...
Date: 2001-10-10 09:16:40
From: Steve Cohen

A relative newbie to these matters, I am trying to define a set of constraints for a series of XML data packets for a particular application. Understanding DTDs, I naturally started out on this march using them. And being a good citizen of cyberspace, I'd always absorbed the pain of using namespaces in my DTDs.


But in order to impress the client, I thought I'd like to try to convert these to schemas to "show off the new technology". My first effort involved using the DTD->Schema converter in XMLSpy. Not good - it
created a document that it's validator wouldn't accept. So much for "simple-to-use" tools.


All right then, let's eschew the "easy way out" and go for understanding. And since XMLSpy is wont to crash on my system, let's investigate TurboXML as well. So I painstakingly hand-crafted schemas with both tools and then tried to create instance documents.


What I find is most disturbing. The schema-namespace coeexistence is anything but peaceful. The assumptions made by the tools lead me into blind alleys that there is no way out of and no way of knowing, in fact, how faithful any of these tools are to the specs.


I read the Kawaguchi-Gudgin debate and it only deepens my frustration. Most of the textbooks show you how to write a schema, sometimes in great detail. What they don't show you is what sorts of instance documents you are contrained to/from using based on the choices made in the schema.


I am going to give this one more crack. If I can't get beyond this soon, I am going to run as fast as I can back to DTDs. The fact that DTDs are NOT xml is beginning to look like a real advantage instead of the disadvantage everyone says it is.


Meantime, if anyone has any advice for me, I'd love to hear it.




Previous Message Previous Message   Next Message No Next Message


Sponsored By: