W3C home > Mailing lists > Public > public-qt-comments@w3.org > February 2004

ORA-SE-341-B: serialization of XQuery DataModel instance is inadequate

From: Stephen Buxton <Stephen.Buxton@oracle.com>
Date: 17 Feb 04 11:31:41
Message-Id: <200402171931.i1HJVf214931@rgmgw6.us.oracle.com>
To: public-qt-comments@w3.org
Cc:

SECTION 2: 

Serialization of the Data Model is important because we want to be able to share Data Model instances between applications over a network in a standard way. Today the spec does not support this (e.g. document boundaries are blurred, scalar values are converted to text nodes).

We should use XML itself to solve the problem. The idea
is the same as using XML to represent XML schema and using XML to represent XQuery (XQueryX).

First, we can  define an XML schema that describes the
XQuery data model , then serialize the XQuery data model instance
based on this XML schema.
The key is to define a comprehensive XML schema to describe an XQuery
data model instance.

For example, consider an XQuery data model instance that consists of 2 items, an
xs:integer  of value 1, followed
by an xs:string of value 'abc'. It can be serialized as:

<xqdm:seq xmlns:xqdm="http://www.w3.org/2004/xqdm" >
   <xqdm:item>
        <xqdm:type>xs_integer<xqdm:type>
        <xqdm:value>1<xqdm:value>
   </xqdm:item>
    <xqdm:item>
        <xqdm:type>xs_string<xqdm:type>
        <xqdm:value>abc<xqdm:value>
   </xqdm:item>
</xqdm:seq>

With this kind of serialization, the Data Model can be serialized in exactly one way.


- Steve B.
Received on Tuesday, 17 February 2004 14:31:44 UTC

This archive was generated by hypermail 2.3.1 : Wednesday, 5 February 2014 07:13:57 UTC