|
[XML-DEV Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] Re: Doc vs. Data
"Rick Jelliffe" <ricko@a...> writes:
> From: "Dare Obasanjo" <dareo@m...>
>
> > I do agree that mixed content is the probably the most relevant
> > differentiator between data-centric & document-centric uses of XML.
>
> I think mixed content also entails some other things:
> * a presumption that data and elements are ordered,
> * a presumption that tags delimit ranges within some larger text stream
> rather than independent atoms of information.
> These presumptions then require some syntactic form for better
> representing information items that are not mutually ordered and do contain
> atoms rather than ranges: hence attribute syntax.
Not to contradict this observation, but I don't think XML attributes
are almost exclusively of value to docheads.
I find an excellent, language-level, round-trippable mapping between
XML attributes and relational ones. Note that the mapping to elements
is not nearly as good.
* Like SQL attributes, XML attributes are semantically unordered.
* SQL attribute names must be unique within a relation, XML attribute
names must be unique in an element.
* SQL attributes can be NULLable; XML attributes can be #IMPLIED.
* Like SQL attributes, XML attributes have names and atomic values
(SQL99 even has an (anti-1NF) array datatype to map to tokenized
attributes).
* XML attributes on an element can be viewed as a relation named by
that element and vice versa.
<PERSON NAME="K. Ari Krupnikov" EMAIL="ari@c..." READS="xml-dev"/>
INSERT INTO PERSON (NAME, EMAIL, READS)
VALUES ("K. Ari Krupnikov", "ari@c...", "xml-dev")
Ari.
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|
|||||||||

Cart








