RE: Atomization Question...

This is actually not the example. The examples are elements with a
content type that is a list "derivation" of an atomic type. E.g.,
xs:IDREFS a user-defined list...

A complex type like the one below is actually a type error for
atomization...

Best regards
Michael 

> -----Original Message-----
> From: Ranjeet Sonone [mailto:ranjeet@ipedo.com]
> Sent: Friday, February 21, 2003 18:25 PM
> To: Michael Burbidge; www-ql@w3.org
> Subject: RE: Atomization Question...
> 
> 
> Atomic values make sense when there is a binding schema for the
> data being represented in XML.
> 
> Consider a schema that defines a complex type as follows:
> 
> <xs:complexType name="stock_quotes">
> 	<xs:sequence minOccurs="0" maxOccurs="unbounded">
> 		<xs:element name="value" type="xs:float"/>
> 	</xs:sequence>
> 	<xs:attribute name="symbol" type="xs:string" use="required"/>
> </xs:complexType>
> 
> The purpose of this element is to give a sequence of stock quote value
> for
> some company over a period of time. Thus, there will be more than
values
> for this stock quote. Note that the primitive type float is used
> for defining the data type of the element value.
> 
> A XML data instance of this schema would be as follows:
> 
> <stock_quotes symbol="abcd">
> 	<value>3.12</value>
> 	<value>4.23</value>
> 	<value>4.23</value>
> 	<value>2.35</value>
> </stock_quotes>
> 
> An XQuery expression for such a snippet that gives you sequence of
nodes
> that contain atomic values could be as follows:
> 
> {-- Assuming that $stock_quotes contain the data as shown above --}
> 
> let $i := dm:document-node($stock_quotes)/value
> return
> $i
> 
> Thus, $i will return the sequence of atomic values.
> 
> The values in the sequence could further be restricted, by using the
> restriction
> on the simple type used for defining the value type, but they still
> qualify as atomic values
> as restricted values would be a subset of the actual domain of values
> for the
> primitive type.
> 
> helps?
> 
> -ranjeet
> 
> 
> 
> 
> 
> 
> 
> -----Original Message-----
> From: Michael Burbidge [mailto:mburbidg@adobe.com]
> Sent: Friday, February 21, 2003 5:23 PM
> To: www-ql@w3.org
> Subject: Atomization Question...
> 
> 
> 
> Under the definition of atomization the specification refers to a node
> whose type value is a sequence of atomic values. Can someone give me a
> snippet of XML that gives an example of a such a node?
> 
> Thanks,
> Michael-

Received on Friday, 21 February 2003 21:36:43 UTC