migrants/queries/step_05_1hop_example.rq
Daniel Hernandez 3d0829aa9d Add Step 5: use well-known vocabularies (Schema.org, OWL, WGS84, SKOS)
SPARQL UPDATE queries add standard vocabulary properties alongside
existing custom predicates: schema:Person/Place/Organization types,
schema:givenName/familyName/birthDate, owl:sameAs for authority links,
wgs84:lat/long for coordinates, skos:Concept/prefLabel for enumerations,
and rdfs:label for persons.
2026-03-01 12:07:01 +01:00

31 lines
990 B
SPARQL

PREFIX xsd: <http://www.w3.org/2001/XMLSchema#>
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX owl: <http://www.w3.org/2002/07/owl#>
PREFIX skos: <http://www.w3.org/2004/02/skos/core#>
PREFIX schema: <https://schema.org/>
PREFIX wgs84: <http://www.w3.org/2003/01/geo/wgs84_pos#>
PREFIX wdtn: <http://www.wikidata.org/prop/direct-normalized/>
PREFIX migrants: <http://example.org/migrants/>
PREFIX person: <http://example.org/migrants/person/>
PREFIX personp: <http://example.org/migrants/person#>
PREFIX work: <http://example.org/migrants/work/>
PREFIX workp: <http://example.org/migrants/work#>
PREFIX location: <http://example.org/migrants/location/>
PREFIX locationp: <http://example.org/migrants/location#>
CONSTRUCT {
?s ?p ?o .
}
WHERE {
{
# Triples about Irene Abendroth (as subject)
?s ?p ?o .
FILTER(?s = person:AbeIre-00)
}
UNION
{
# Triples from other tables referencing Irene Abendroth
?s ?p ?o .
?s ?ref person:AbeIre-00 .
}
}