OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.

 


Help: OASIS Mailing Lists Help | MarkMail Help

 


 

   RE: XQL Challenge (also, Design for Queryability)

[ Lists Home | Date Index | Thread Index ]
  • From: Ronald Bourret <rbourret@ito.tu-darmstadt.de>
  • To: "xml-dev@ic.ac.uk" <xml-dev@ic.ac.uk>
  • Date: Thu, 8 Jul 1999 13:41:25 +0200

Steve Muench wrote:

> If your data is already in a database, and you already
> know the SQL that gets you the info you need, why not
> combine these two pieces of info with a utility like
> the Oracle XML SQL Utility for Java and...
>
>  -> Query the data with full speed and power of your database
>  -> Query it from any point of view required for the app at hand
>  -> Return on-the-fly XML results from what you find
>
> Using something like an Object View you can predefine
> a rich structure to your data, query it using SQL3 object
> query syntax, and get the rich structure back in the XML
> for the results. You can see the "Insurance Claim" demo
> that comes with the Oracle XSQL Servlet for an example.

I've looked at the examples, but unfortunately don't have an Oracle 
database available at the moment to execute them. The documentation states 
that the output of a SELECT statement is returned as XML nested three 
levels deep: rowset, row, and column. Do object views allow you to get 
deeper nesting?

For example, suppose I have the following tables:

   SalesOrders
      SONumber
      CustNumber

   Lines
      SONumber
      LineNumber
      PartNumber
      Quantity

Can I then define an object view over these tables such that I have 
SalesOrder objects, each of which has an array of Lines objects?  And 
supposing I can do this, does executing a SELECT statement in a document 
processed by the XSQL Servlet producing a flat or nested XML document? That 
is, do I get the following document:

   <rowset>
      <SalesOrder>
         <SONumber>...</SONumber>
         <CustNumber>...</CustNumber>
         <Line>
            <LineNumber>...</LineNumber>
            <PartNumber>...</PartNumber>
            <Quantity>...</Quantity>
         </Line>
         ...
         <Line>
            <LineNumber>...</LineNumber>
            <PartNumber>...</PartNumber>
            <Quantity>...</Quantity>
         </Line>
      </SalesOrder>
   </rowset>

or are there still only three levels of nesting, with SONumber and 
CustNumber repeated for each Line:

   <rowset>
      <SalesOrder>
         <SONumber>...</SONumber>
         <CustNumber>...</CustNumber>
         <LineNumber>...</LineNumber>
         <PartNumber>...</PartNumber>
         <Quantity>...</Quantity>
      </SalesOrder>
      ...
      <SalesOrder>
         <SONumber>...</SONumber>
         <CustNumber>...</CustNumber>
         <LineNumber>...</LineNumber>
         <PartNumber>...</PartNumber>
         <Quantity>...</Quantity>
      </SalesOrder>
   <rowset>

Thanks.

-- Ron Bourret


xml-dev: A list for W3C XML Developers. To post, mailto:xml-dev@ic.ac.uk
Archived as: http://www.lists.ic.ac.uk/hypermail/xml-dev/ and on CD-ROM/ISBN 981-02-3594-1
To (un)subscribe, mailto:majordomo@ic.ac.uk the following message;
(un)subscribe xml-dev
To subscribe to the digests, mailto:majordomo@ic.ac.uk the following message;
subscribe xml-dev-digest
List coordinator, Henry Rzepa (mailto:rzepa@ic.ac.uk)






 

News | XML in Industry | Calendar | XML Registry
Marketplace | Resources | MyXML.org | Sponsors | Privacy Statement

Copyright 2001 XML.org. This site is hosted by OASIS