0

I am a beginner in SPARQL and I would like to know if it is possible to return relationships between two objects. For example I would like to write a SPARQL query which returns the relationship between Thierry Henry and Arsenal in dbpedia.

L.B
  • 139
  • 2
  • 12

1 Answers1

7
SELECT ?relationship
WHERE {
  <http://dbpedia.org/resource/Thierry_Henry> 
  ?relationship 
  <http://dbpedia.org/resource/Arsenal_F.C.>
}

i.e.:

show me the predicates (?relationship) where the subject is the DBPedia resource Thierry_Henry and the object is the DBPedia resource Arsenal_F.C.

..which results to:

dbpedia:ontology/team
dbpedia2:clubs

..which apparently means that Thierry Henry was part of the Arsenal team and belonged to the Arsenal Football Club. See the result on DBPedia SPARQL Explorer.

trashr0x
  • 6,457
  • 2
  • 29
  • 39