[XML-DEV Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

Re: XQuery & Several records (instead of one xml-field)

  • From: Liam Quin <liam@w...>
  • To: Mukul Gandhi <gandhi.mukul@g...>
  • Date: Fri, 19 Oct 2007 00:54:17 -0400

Re:  XQuery & Several records (instead of one xml-field)
On Fri, Oct 19, 2007 at 09:12:46AM +0530, Mukul Gandhi wrote:
[...]
> Suppose, that a RDBMS table is defined like following:
> 
> Table: X
> col1 - number (10),
> col2 - varchar2 (15),
> col3 - XMLType
> 
> The column "col3" is of type XMLType (this is just illustrating the
> concept, and does not follow a syntax of a product or a standard).
> 
> Now the XQuery program (the XQuery engine is probably embedded in the
> RDBMS) can query the column "col3". Something like:
> 
> xquery db-func:XML-column('X.col3')/root/a/b/c

Right.

> Now my questions are
> 1) It is probably possible for a XQuery engine to reuse it's design
> (i.e. for the XML infoset/PSVI) to construct a data model instance
> from the XMLType column. Do most of the XQuery engines embedded in the
> RDBMS work this way?

The Xpath 2.0 and XQuery 1.0 Data Model is conceptual.  That is, the
database doesn't actually have to construct anything at all, as long
is it generates the right results.

However, if you have specified that the column contains XML, and asked
for it to be indexed, it's likely that no pointy-bracket parsing will
be needed at runtime for many queries.

DB2 at least have released a white paper showing that their XQuery
implementation accesses the underlying data store and does not need
to go through the SQL engine; I believe the same is true for Oracle,
and possibly also Microsoft SQL Server.

> 2) Supposing a RDBMS table is defined like this (a very simple
> traditional definition):
> Table: X
> col1 - number (10),
> col2 - varchar2 (15),
> col3 - float
> 
> Can a XQuery engine work on this table structure?
Yes.

That is, some can and some can't, and some do it via SQL and
JDBC or ODBC, and some perhaps more efficiently.

Liam

-- 
Liam Quin, W3C XML Activity Lead, http://www.w3.org/People/Quin/
http://www.holoweb.net/~liam/ * http://www.fromoldbooks.org/
W3C participant/staff contact for the W3C XML Query Working Group


[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index]


PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
 

Stylus Studio has published XML-DEV in RSS and ATOM formats, enabling users to easily subcribe to the list from their preferred news reader application.


Stylus Studio Sponsored Links are added links designed to provide related and additional information to the visitors of this website. they were not included by the author in the initial post. To view the content without the Sponsor Links please click here.

Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.