Re: Reverse Mapping RDF2RDF

On Sat, 2010-11-20 at 07:08 -0500, Eric Prud'hommeaux wrote:
> * Ivan Herman <ivan@w3.org> [2010-11-20 11:24+0100]
> > I wonder where this agenda item comes from... I guess it was triggered by my question to Michael at the SWCG call.
> > 
> > I did not have anything very complicated in mind, just a question... we are talking about the possibility of translating SPARQL queries to the SQL calls on-the-fly.
> 
> Ahh, to me "reverse mapping" denotes a mapping from RDF graphs to RDB tables (which has its own use cases and advocates but is outside this charter). As to exploiting an rdb2rdf mapping as a virtual view, I believe that it is what every one of us has done and aims to do interoperably. There were a series of presentations at the beginning of the WG's life 
>   http://www.w3.org/2001/sw/rdb2rdf/wiki/Initial_Round_of_Presentations
> which showcased mostly the different strategies for sparql2sql. No one as yet has demonstrated sql2sparql.
> 
> For consistency, we could adopt some vocabulary:
>   rdb2rdf: mapping relational data to rdf graphs.
>   rdf2rdb: mapping rdf graphs to relational data.
>   sparql2sql: mapping sparql queries to sql queries.
>   etc.

+1

> I believe we see rdb2rdf as in scope, rdf2rdb as out of scope but if someone out there wants to tool on it and advise us, great. I expect we'll all have our strategies for sparql2sql, and that while it's not up to RDB2RDF to mandate one, it is our job to make sure that our rdb2rdf mapping language enable sparql2sql. 

We have to ensure that any rdb2rdf solution (direct mapping, datalog
rules, r2rml) can enable sparql2sql.

> >   I was just wondering whether there was a systematic consideration whether that is possible at all if I write an R2RML or use the direct mapping; if not, under which circumstances, and whether this is something that the author of an R2RML instance can influence. I saw in the inverseExpression term in R2RML; is that enough for what I meant?
> > 
> > Maybe some sort of primer text should include more information on that.
> 
> There's some commented text in both directMapping and UC&R showing "equivalence" of SPARQL and SQL queries over the leading examples in those documents.

The relation between RDB, RDF, SPARQL and SQL should be formalized and
should not rely only on examples. It's called semantics preservation
-- a well-known problem in the compilation field -- and IMO it should
be in a normative section.

Eirc and I are totally confident that in the case of the direct
mapping, we can map any SPARQL query to its equivalent SQL query.

> I scare-quote equivalence because SPARQL returns RDF terms and SQL, unless you significantly change the wire protocol, returns strings which can be parsed to RDF terms. 

I don't understand, a SQL result is a SQL table, not a bunch of
strings to be parsed. It's perfectly defined (the same way than for
the relation algebra).

Alexandre.

> 
> > That is all...
> > 
> > Ivan
> > 
> > On Nov 19, 2010, at 20:20 , Juan Sequeda wrote:
> > 
> > > Hi Ivan,
> > > 
> > > Per the agenda, it states:
> > > 
> > > 4. Reverse Mapping
> > > Question from Ivan re RDF2RDB (it's not in our charter, but maybe some WG
> > > members plan to address this?)
> > > 
> > > I'm curious about RDF2RDB. Could you expand on this. What are the use cases? Requirements?
> > > 
> > > Thanks
> > > 
> > > Juan Sequeda
> > > +1-575-SEQ-UEDA
> > > www.juansequeda.com
> > 
> > 
> > ----
> > Ivan Herman, W3C Semantic Web Activity Lead
> > Home: http://www.w3.org/People/Ivan/
> > mobile: +31-641044153
> > PGP Key: http://www.ivan-herman.net/pgpkey.html
> > FOAF: http://www.ivan-herman.net/foaf.rdf
> > 
> > 
> > 
> > 
> > 
> 
> 
> 

Received on Saturday, 20 November 2010 15:23:28 UTC