W3C home > Mailing lists > Public > public-lod@w3.org > October 2009

Re: DBpedia SPARQL Endpoint and Transitive Queries

From: Kingsley Idehen <kidehen@openlinksw.com>
Date: Thu, 08 Oct 2009 11:44:52 -0400
Message-ID: <4ACE08F4.30501@openlinksw.com>
To: Alexandre Passant <alexandre.passant@deri.org>
CC: "dbpedia-discussion@lists.sourceforge.net" <dbpedia-discussion@lists.sourceforge.net>, "public-lod@w3.org" <public-lod@w3.org>
Alexandre Passant wrote:
> Hi,
>
> On 8 Oct 2009, at 16:09, Kingsley Idehen wrote:
>
>> All,
>>
>> The intersection of Leigh Dodds SPARQL extensions survey [1], 
>> imminent official release of Virtuoso 6.0 (DBpedia basic and Live 
>> already use this, ditto LOD Cache, and B3S public endpoints), and an 
>> old post by Bernard Vatant re. skos:broader, has lead to this simple, 
>> but powerful example of  Virtuoso's Transitive Option extension for 
>> SPARQL :
>>
>> #Transitive Option Off
>>
>> PREFIX p: <http://dbpedia.org/property/>
>> PREFIX dbpedia: <http://dbpedia.org/resource/>
>> PREFIX category: <http://dbpedia.org/resource/Category:>
>> PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
>> PREFIX skos: <http://www.w3.org/2004/02/skos/core#>
>> PREFIX geo: <http://www.georss.org/georss/>
>>
>> SELECT DISTINCT ?m ?n ?p ?d
>> WHERE {
>>  ?m rdfs:label ?n.
>>  ?m skos:subject ?c.
>>  ?c skos:broader category:Churches_in_Paris.
>>  ?m p:abstract ?d.
>>  ?m geo:point ?p
>> FILTER ( lang(?n) = "fr" )
>> FILTER ( lang(?d) = "fr" )
>> }
>>
>> #Transitive Option On
>>
>> PREFIX p: <http://dbpedia.org/property/>
>> PREFIX dbpedia: <http://dbpedia.org/resource/>
>> PREFIX category: <http://dbpedia.org/resource/Category:>
>> PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
>> PREFIX skos: <http://www.w3.org/2004/02/skos/core#>
>> PREFIX geo: <http://www.georss.org/georss/>
>>
>> SELECT DISTINCT ?m ?n ?p ?d
>> WHERE {
>>  ?m rdfs:label ?n.
>>  ?m skos:subject ?c.
>>  ?c skos:broader category:Churches_in_Paris OPTION (TRANSITIVE).
>>  ?m p:abstract ?d.
>>  ?m geo:point ?p
>> FILTER ( lang(?n) = "fr" )
>> FILTER ( lang(?d) = "fr" )
>> }
>>
>>
>
> As skos:broader is not transitive [1] but its superproperty 
> skos:broaderTransitive is, shouldn't the second query be
>
>  ?c skos:broaderTransitive category:Churches_in_Paris OPTION 
> (TRANSITIVE).
Yes, but as you can see the option controls how the engine processes the 
query, and caters for the change re. skos:broader to 
skos:broaderTransitive :-)

Remember, the problem highlighted by Bernard honed specifically into the 
2004 - 2008 changes re. skos in this particular area.


Kingsley

>
> Best,
>
> Alex.
>
> [1] http://www.w3.org/TR/2009/REC-skos-reference-20090818/#L2413
>
>
>
>>
>> -- 
>>
>>
>> Regards,
>>
>> Kingsley Idehen          Weblog: http://www.openlinksw.com/blog/~kidehen
>> President & CEO OpenLink Software     Web: http://www.openlinksw.com
>>
>>
>>
>>
>>
>
> -- 
> Dr. Alexandre Passant
> Digital Enterprise Research Institute
> National University of Ireland, Galway
> :me owl:sameAs <http://apassant.net/alex> .
>
>
>
>
>
>
>


-- 


Regards,

Kingsley Idehen	      Weblog: http://www.openlinksw.com/blog/~kidehen
President & CEO 
OpenLink Software     Web: http://www.openlinksw.com
Received on Thursday, 8 October 2009 15:45:27 UTC

This archive was generated by hypermail 2.3.1 : Sunday, 31 March 2013 14:24:23 UTC