W3C home > Mailing lists > Public > www-ws@w3.org > July 2002

RE: W3C XQuery for Web Service discovery?

From: Kingsley Idehen <kidehen@openlinksw.com>
Date: Thu, 4 Jul 2002 13:33:26 +0100
To: <www-ql@w3.org>, <www-ws@w3.org>
Message-ID: <002e01c22356$fee11a40$fb01a8c0@KingsleyGRX>

Dan,

> -----Original Message-----
> From: www-ws-request@w3.org [mailto:www-ws-request@w3.org] On Behalf
Of
> Dan Brickley
> Sent: Thursday, July 04, 2002 10:53 AM
> To: www-ql@w3.org; www-ws@w3.org
> Subject: W3C XQuery for Web Service discovery?
> 
> 
> 
> Hi all
> 
> Apologies for the crosspost. I'm trying to find out if
> (and how) XQuery[1] is being used in a Web Services context.
> Most specifically, whether folk are using it for service
> discovery (eg. querying aggregates of WSDL descriptions).
> URLs or summaries to the list(s) would be greatly appreciated.
> 
> thanks,
> 
> Dan
[Kingsley's Response] 
All,
 
Quick FYI re. our recently released Universal Server product (OpenLink
Virtuoso) includes XQUERY support. This release enables the creation of
XML Query Template files that includes XQUERY statements. These
Templates are consumable either directly via a URL or as SOAP operations
(Web Services).  The XML documents can take the following forms:
 
1. SQL-XML - These are Valid (XML Schema or DTD based) or Well Formed
XML 
docs generated on the fly from homogeneous or heterogeneous databases
(Native Virtuoso SQL Data or third party databases accessible via ODBC
or JDBC).
 
2. XML or XHTML documents imported into Virtuoso via WebDAV
 
3. Document created and deposited into Virtuoso via any XML editor (e.g.
XML Spy)
 
Here are some examples using the live Virtuoso server instance at:
http://demo.openlinksw.com:8890/xqdemo
 
1. Query Statement (stored as query template) re. Use Case R, sample
query 1.4.4.10:
 
<result>
{
   for $highbid in document("bids.xml")//bid_tuple,
       $user in document("users.xml")//user_tuple
   where $user/userid = $highbid/userid
     and $highbid/bid =
            max(document("bids.xml")//bid_tuple
                   [itemno = $highbid/itemno]/bid)
   return
     <high_bid>
        { $highbid/itemno }
        { $highbid/bid }
        <bidder> { $user/name/text() } </bidder>
     </high_bid> sortby (itemno)
}
</result>
 
URL Access to Query Template (which materializes the resultset):
http://demo.openlinksw.com:8890/DAV/xqdemo/sqlxml-bids.xml
 
WSDL endpoint for consuming this Template exposed as a SOAP Operation
(Web Service):
http://demo.openlinksw.com:8890/demo1/services.wsdl

Web Services Interaction Endpoint for testing this Web Service:
http://demo.openlinksw.com:8890/demo1/services.vsmx?operation=sqlxml_bid
s or for a general view of other related Web Services demos
http://demo.openlinksw.com:8890/demo1/services.vsmx 

 
 
2. Query Statement (stored as query template) re. Use Case XMP, sample
query 1.1.9.10a:
 
<results>
   {
      let $doc := document("prices.xml")
      for $book in $doc/prices/book
      let $t := $book//title, $p := $doc/prices/book[title = $t]/price
      return
        (
          $book,
         <minprice title = { string($t) } >
            { if (not(empty($p))) then string(min($p)) else <unknown/> }
         </minprice>
        )
   }
</results>
 
URL Access to Query Template (which materializes the resultset):
http://demo.openlinksw.com:8890/DAV/xqdemo/sqlxml-prices.xml

WSDL endpoint for consuming this Template exposed as a SOAP Operation
(Web Service):
http://demo.openlinksw.com:8890/demo1/services.wsdl

Web Services Interaction Endpoint for testing this Web Service:
http://demo.openlinksw.com:8890/demo1/services.vsmx?operation=sqlxml_pri
ces or for a general view of other related Web Services demos
http://demo.openlinksw.com:8890/demo1/services.vsmx

 
The are many more XML and Web Services etc. tutorials at:
http://demo.openlinksw.com:8890/tutorial (note: these aren't necessarily
XQUERY based).
 
Regards,
Kingsley Idehen
OpenLink Software
http://www.openlinksw.com/virtuoso/whatis.htm 

> 
> 
> 
> 
> [1] http://www.w3.org/TR/xquery/
>     XQuery 1.0: An XML Query Language
>     W3C Working Draft 30 April 2002
> 
> 
> 
> --
> mailto:danbri@w3.org
> http://www.w3.org/People/DanBri/
Received on Thursday, 4 July 2002 08:24:50 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Tuesday, 3 July 2007 12:25:40 GMT