CORDIS Archive

View the original page arrowbar Legal Noticebar Print the page
This page has been archived. It will no longer be updated.
Important legal notice -Information on this site is subject to a disclaimer and a copyright notice
« ISTweb » You are here : ISTweb | KA3 | IAF | SWT Presentations | Querying RDF
IAF Home
IAF Calls & Action Lines
Projects
News & Events
:: IAF Workshops
Who's who
Useful Links
Activities

« Table of Contents

Querying RDF using an SQL-ish query language

(Libby Miller, ILRT, University of Bristol)

The major query APIs in Java for RDF have been graph navigation APIs, which work at a very low level, for example Sergay Melnik's RDF API and Brain McBride's Jen API. A typical query would be

Model find (Resource, Property, Resource); where any argument can be null.

Navigating RDF graphs at this level of detail is necessary for the specialist RDF application developer, but for the mainstream web developer low level queries like this are offputting, and as it turns out, unnecessary. It is important to simplify the access to RDF data stores, so that simple and ontology-enabled RDF data stores can be exposed to mainstream developers. We have developed a prototype query langauge which can do this.

A great deal of work has been done on semi-structured query languages: the work here draws on R. V. Guha's RDFDB QL and also the Algae work by Eric Prud'hommeaux, the QL described in the recent paper by Karvounarakis, Christophides, Plexousakis and Alexaki on RQL, as well as those described in 'Data on the Web' by Abiteboul, Buneman and Suciu.

We have taken the JDBC API and RSS as canonically mainstream technologies that can be usefully co-opted by RDF. We have built a demonstration query system over the top of the Java Jena and Melnik APIs which uses an SQL-like query language to query in-memory or on-disk (Postgres) RDF data stores.

We used a cut-down JDBC API to query the RDF data stores. This means that there is a familiar interface for Java developers to the RDF data store, which returns a ResultSet object. It also means that we can write simple jsp pages to query RDF databases and display the results.

One application of this is to the new RSS 1.0 channel data. RSS 1.0 is an RDF format. Its usual application is for providing a summary view of information from a site, which can then be displayed by a viewer or aggregator. Since it is implemented in RDF, however, we can also aggregate the data and query it using the SQL-like query language. For example, if the RSS data includes information about job adverts, we could have a query:

SELECT ?z ?a FROM http://ilrt.org/discovery/2000/11/rss-query, http://ilrt.org/discovery/2000/11/rss-query WHERE ({job::advertises} ?x ?y) ({job::salary} ?y ?z) ({job::title} ?y ?a) AND ?z > 55000 USING job FOR http://ilrt.org/discovery/2000/11/rss-query

producing a result set
?y ?z web developer 60000 perl programmer 56000

Result: simple or complex RDF data becomes accessible to mainstream Java server-side developers.
Thanks to Dan Brickley for much useful input.

More detail is at: http://ilrt.org/discovery/2000/10/swsql
related work: http://ilrt.org/discovery/2000/11/rss-query
demo/download: http://swordfish.rdfweb.org/rdfquery
RQL: http://www.ics.forth.gr/proj/isst/RDF/RQL/rql.html
Algae: http://www.w3.org/1999/02/26-modules/User/Algae-HOWTO.html
Guha's RDFDB: http://web1.guha.com/rdfdb



Last updated: 20 | 02 | 2002


ISTweb Home Search ISTweb EC home FP5 home Disclaimer
IST news More links Information Society and Media DG IST calls Back to top