W3C home > Mailing lists > Public > www-ql@w3.org > January to March 2003

An XQuery data model question...

From: Michael Burbidge <mburbidg@adobe.com>
Date: Tue, 18 Feb 2003 10:11:26 -0800
To: www-ql@w3.org
Message-Id: <65795F8A-436C-11D7-9453-003065F9651E@sea.adobe.com>

The document "XQuery 1.0 and XPath 2.0 Data Model" states in the 
introduction that "every value handled by the data model is a sequence" 
and later says that a "sequence is an oredered collection of nodes, 
atomic values or any mixture of nodes and atomic values." It then 
states that "a sequence cannot be a member of a sequence."

Given this definition, is the following a valid XQuery expression? Note 
that it is a sequence containing sequences.

((1, 2), (3, 4))

According to the Microsoft XQuery Demo the result of this expression is 
1 2 3 4, although it's difficult to tell from the UI, I interpret that 
to mean a sequence of four numbers.

Is it wrong, if not, can someone explain at what point in the 
evaluation process of this expression do the nested sequences get 
flattened? Where in the specification does it talk about this issue?

Thanks,
Michael-
Received on Tuesday, 18 February 2003 13:08:22 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Saturday, 22 July 2006 00:10:18 GMT