Xml and Object/Relational Database

Steve Muench SMUENCH at us.oracle.com
Thu Dec 3 20:33:55 GMT 1998


In Oracle8i we're taking a approach to allow developers 
the flexibility of storing XML Documents in any way they 
choose along the spectrum of: 
 
Single, Indexed text-BLOB ==> Fully Expanded into Foreign-Key linked Tables 
 
The middle ground is that highly structured data gets mapped into 
a set of related tables and structured text markup doc fragments 
get mapped into text-BLOB's. 
 
The simple example I use to show off why this might be interesting 
would be to consider an Insurance Claim XML document like: 
 
<?xml version="1.0"?> 
<InsuranceClaim> 
  <ClaimID>12345</ClaimID> 
  <LossCategory>7</LossCategory> 
  <Settlements> 
    <Payment> 
      <Payee>Borden Real Estate</Payee> 
      <Date>12-OCT-1998</Date> 
      <Amount>200000</Amount> 
      <Approver>JCOX</Approver> 
    </Payment> 
  </Settlements> 
  <DamageReport> 
    A massive <Cause>Fire</Cause> ravaged the building and 
    <Casualties>12</Casualties> people were killed. Early 
    FBI reports indicate that <Motive>arson</Motive> is 
    suspected. 
  </DamageReport> 
  </InsuranceClaim>   
 
If you map the settlement payment sections into tables and columns 
and the DamageReport doc fragment into a text blob, then you can 
query over your datawarehouse of Insurance Claims to answer a 
question like: 
 
"How much money has Jim Cox approved to date in settlement 
 payments for arson-related fire claims? " 
 
Using a straightforward SQL statement like: 
 
SELECT SUM(csp.Amount) 
  FROM Claim_Header ch, 
       Claim_Settlements cs, 
       Claim_Settlement_Payments csp 
WHERE csp.Approver = 'JCOX' 
   AND CONTAINS (DamageReport, 'Arson WITHIN Motive') > 0 
   AND CONTAINS (DamageReport, 'Fire WITHIN Cause'  ) > 0 
   AND . . . /* Join Clauses */ 
 
We're participating in the W3C Query Language workshop today and tomorrow 
(as well as follow-on W3C XML Query work) to help shape the eventual W3C 
standard syntax for XML document queries. In the future, you may have 
alternative syntaxes to answer the same questions of your enterprise 
information, but this is our near term game plan. 
 
____________________________________________________________________________ 
 Steve  | Consulting PM & XML Technology Evangelist | smuench at oracle.com 
 Muench |      Java Business Objects Dev Team       | geocities.com/~smuench 
 
                Oracle XML Homepage http://www.oracle.com/xml
-------------- next part --------------
An embedded message was scrubbed...
From: Kacper Nowicki <kacper at odi.com>
Subject: Re: Xml and Object Database
Date: 03 Dec 98 11:19:42
Size: 2630
Url: http://mailman.ic.ac.uk/pipermail/xml-dev/attachments/19981203/bb9b64a8/attachment.eml


More information about the Xml-dev mailing list