Professional Documents
Culture Documents
44
Result :
?title
SPARQL handbook
45
foaf:name
foaf:mbox
foaf:name
foaf:mbox
foaf:mbox
46
47
mbox
<mailto:jlow@example.com>
<mailto:peter@example.org>
48
49
SELECT QUIZZES
DBpedia SPARQL Endpoint
50
Quiz (1)
1.1 Find all available information on J. K. Rowling from DBpedia
1.2 Find only J. K. Rowlings birthdate from DBpedia
51
Answer (1)
SELECT ?p ?o
WHERE {
<http://DBpedia.org/resource/J._K._Rowling> ?p ?o;
}
SELECT distinct ?o
WHERE {
<http://DBpedia.org/resource/J._K._Rowling> ?p ?o;
dbo:birthdate
?o
}
52
Quiz (2)
On DBpedia, find people who were lead actors in the movie
Jurassic Park.
53
Answer (2)
select ?person
WHERE {
<http://DBpedia.org/resource/Jurassic_Park> dbo:starring ?
person.
}
54
Quiz (3)
On DBpedia, find people who were born in South Korea.
55
Answer (3)
SELECT
?s
WHERE
{
?s dbo:birthPlace
dbr:South_Korea.
}
ORDER BY ASC(?s)
56
Quiz (4)
4.1 Find East Asian islands on DBpedia.
4.2 Organize the results in ascending order.
57
Answer (4)
SELECT
?s
WHERE
{
?s rdf:type dbo:Island.
?s dbo:location dbr:East_Asia.
}
ORDER BY ASC(?s)
58
Quiz (5)
5.1 Find books on DBpedia.
5.2 Find the author of
The_7_Habits_of_Highly_Effective_People on DBpedia.
5.3 Find the total number of pages the aforementioned book.
59
Answer (5)
SELECT ?book_name
WHERE {
?book_name rdf:type dbo:Book.
}
SELECT ?author
WHERE {
<http://DBpedia.org/resource/The_7_Habits_of_Highly_Effective_People>
dbo:author ?author.
}
60
Answer (5)
SELECT ?author ?page
WHERE {
<http://DBpedia.org/resource/The_7_Habits_of_Highly_Effective_People>
dbo:author ?author;
dbo:numberOfPages ?page.
}
61
Quiz (6)
7.1 Using dbr:Walt_Disney_Studios_Motion_Pictures, find
62
Answer (6)
select ?s
where {
?s dbo:distributor dbr:Walt_Disney_Studios_Motion_Pictures.
}
select ?s
where {
?s dbo:distributor dbr:Walt_Disney_Studios_Motion_Pictures.
?s dct:subject dbc:Walt_Disney_Animation_Studios_films.
}
63
Quiz (7)
Find living writers on DBpedia, restricting the results using
64
Answer (7)
SELECT ?s ?birthYear
WHERE
{
?s a dbo:Writer .
?s dbo:birthYear ? birthYear.
FILTER (? birthYear<= 1966-07-10 ^^xsd:date)
FILTER NOT EXISTS {?s dbo:deathYear ?deathyear}
}
ORDER BY ASC(?s)
65
Quiz (8)
9.1 Find all musicians on DBpedia.
9.2 Narrow the ensuing results to albums with the artist
66
Answer (8)
SELECT ?musicalartist
WHERE {
?musicalartist a dbo:MusicalArtist.
}
SELECT ?albumName
WHERE {
?album dbo:producer <http://DBpedia.org/resource/Timbaland> .
?album rdfs:label ?albumName .
}
67
Answer (8)
SELECT ?albumName ?releaseDate
WHERE {
?album dbo:producer <http://DBpedia.org/resource/Timbaland> ;
dbo:releaseDate ?releaseDate.
FILTER (?releaseDate >="1990-01-01"^^xsd:date
&& ?releaseDate <= "1999-12-31" ^^xsd:date)
?album rdfs:label ?albumName .
}
ORDER BY ASC (?releaseDate)