Using Jena ARQ, I was able to use the following query to get the data that you think is interested in the Linked Base DataBase SPARQL endpoint:
PREFIX dcterms: <http://purl.org/dc/terms/> PREFIX movie: <http://data.linkedmdb.org/resource/movie/> SELECT ?id ?filmTitle ?actorName WHERE { VALUES ?filmTitle { "The Matrix" } SERVICE <http://data.linkedmdb.org/sparql> { ?film a movie:film ; movie:filmid ?id ; dcterms:title ?filmTitle ; movie:actor [ a movie:actor ; movie:actor_name ?actorName ]. } }
data.n3 is an empty file, since arq requires the --data argument, even if the SERVICE keyword means that we are requesting remote data.
$ arq --query query.sparql --data data.n3 ----------------------------------------------------------------------------------------- | id | filmTitle | actorName | ========================================================================================= | "38146"^^<http://www.w3.org/2001/XMLSchema#int> | "The Matrix" | "Keanu Reeves" | | "38146"^^<http://www.w3.org/2001/XMLSchema#int> | "The Matrix" | "Laurence Fishburne" | | "38146"^^<http://www.w3.org/2001/XMLSchema#int> | "The Matrix" | "Hugo Weaving" | | "38146"^^<http://www.w3.org/2001/XMLSchema#int> | "The Matrix" | "Joe Pantoliano" | | "38146"^^<http://www.w3.org/2001/XMLSchema#int> | "The Matrix" | "Gloria Foster" | | "38146"^^<http://www.w3.org/2001/XMLSchema#int> | "The Matrix" | "Carrie-Anne Moss" | -----------------------------------------------------------------------------------------
Removing the line VALUES ?filmTitle ... expands the search to all the films and their actors, of course.
The properties used in your request are different from the real properties used in LMDB, which makes it difficult to understand what different options might be. It could be rdfs:label instead of dcterms:title , or lines with or without language tags, etc.
source share