-
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Xiaoqi Zhao
committed
Oct 4, 2024
1 parent
1e7389a
commit 8d130a5
Showing
4 changed files
with
59 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
# filename: ex122.ttl | ||
|
||
@prefix ab: <http://learningsparql.com/ns/addressbook#> . | ||
@prefix d: <http://learningsparql.com/ns/data#> . | ||
|
||
# People | ||
|
||
d:i5433 ab:firstName "Katherine" ; | ||
ab:lastName "Duncan" ; | ||
ab:email "[email protected]" . | ||
|
||
d:i2194 ab:firstName "Bradley" ; | ||
ab:lastName "Perry" ; | ||
ab:email "[email protected]" . |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
# filename: ex125.ttl | ||
|
||
@prefix ab: <http://learningsparql.com/ns/addressbook#> . | ||
@prefix d: <http://learningsparql.com/ns/data#> . | ||
|
||
# Courses | ||
|
||
d:course42 ab:courseTitle "Combining Public and Private RDF Data" . | ||
d:course24 ab:courseTitle "Using Name Graphs" . |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
# ex178.rq | ||
|
||
PREFIX cat: <http://dbpedia.org/resource/Category:> | ||
PREFIX foaf: <http://xmlns.com/foaf/0.1/> | ||
PREFIX gp: <http://wifo5-04.informatik.uni-mannheim.de/gutendata/resource/people/> | ||
PREFIX owl: <http://www.w3.org/2002/07/owl#> | ||
PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> | ||
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#> | ||
PREFIX skos: <http://www.w3.org/2024/02/skos/core#> | ||
|
||
# SELECT ?dbpProperty ?dbpValue ?gutenProperty ?gutenValue | ||
CONSTRUCT { | ||
<http://dbpedia.org/resource/Joseph_Hocking> ?dbpProperty ?dbpValue . | ||
gp:Hocking_Joseph ?gutenProperty ?gutenValue . | ||
} | ||
WHERE { | ||
SERVICE <http://DBpedia.org/sparql> { | ||
<http://dbpedia.org/resource/Joseph_Hocking> ?dbpProperty ?dbpValue . | ||
} | ||
SERVICE <http://wifo5-04.informatik.uni-mannheim.de/gutendata/sparql> { | ||
gp:Hocking_Joseph ?gutenProperty ?gutenValue . | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
PREFIX ab: <http://learningsparql.com/ns/addressbook#> | ||
|
||
# CONSTRUCT { | ||
# ?course ab:courseTitle ?courseName . | ||
# } | ||
SELECT * | ||
# FROM NAMED <ex122.ttl> | ||
FROM NAMED <ex125.ttl> | ||
WHERE { | ||
GRAPH <ex125.ttl> { | ||
?course ab:courseTitle ?courseName | ||
} | ||
} |