Warning:
This wiki has been archived and is now read-only.

SPARQLX

From SPARQL Working Group
Jump to: navigation, search


Feature: SPARQLX

An XML Schema/toolchain friendly syntax for SPARQL queries so that SPARQL queries can be manipulated in "normal" XML ways and be used appropriately in WSDL.

Feature description

SPARQL's SQL-esque syntax is quite writable and readable. However, it is largely "invisible" to the XML toolchain, i.e., schema aware editors, XSTL, XQuery, data binding, Schematron, etc. This is a very powerful and widespread toolchain. SPARQLX would allow SPARQL queries to be manipulated by that toolchain effectively.

It is important that SPARQLX produce a sensible DOM and, indeed, a sensible PSVI. For this reason, an RDF/XML serialization -- or even a TriX based serialization -- will not meet the desiderata.

Example

This example uses the SPARQLX syntax proposed by Kendall Clark in the last working group.

SELECT ?v WHERE { ?x ?p "cat" }
<rdf-query xmlns="http://www.w3.org/2001/sw/DataAccess/sparql-xml-syntax/">
   <select>
       <variable name="v"></variable>
   </select>
   <query-pattern>
       <triple-pattern>
           <subject>
               <variable name="x"></variable>
           </subject>
           <predicate>
               <variable name="p"></variable>
           </predicate>
           <object>
               <literal>cat</literal>
           </object>
       </triple-pattern>
   </query-pattern>
</rdf-query>

Existing Implementation(s)

None.

Existing Specification / Documentation

http://lists.w3.org/Archives/Public/public-rdf-dawg/2005JanMar/0414.html

Compatibility

Query engines would have to be modified to accept (natively) SPARQLX queries. However, since SPARQLX shall be (I hope) a transliteration of SPARQL, this is not a large burden and can easily be handled by external tools (e.g., an XSLT). I expect only tools that want to make use of SPARQLX directly need be changed.

Links to postponed Issues

Related Features

List and possibly link to other use cases or extensions that relate to that use case. That will help us grouping them together in the end.

Champions

Bijan Parsia, University of Manchester

Use cases

A description of one or more use cases, the solution of which requires this feature. Multiple use cases can be added to each feature.

References

SPARQL in RDF : The SPIN SPARQL Syntax
From comments/2009Mar/0010