Question: Give me all actors starring in movies directed by and starring William Shatner.
SPARQL query:
PREFIX onto: <http://dbpedia.org/ontology/> PREFIX prop: <http://dbpedia.org/property/> PREFIX res: <http://dbpedia.org/resource/> SELECT DISTINCT ?uri WHERE { ?x onto:director res:William_Shatner . ?x onto:starring res:William_Shatner . { ?x onto:starring ?uri . } UNION { ?x prop:starring ?uri . } }