SPIDER

Examples

On this page examples of the usage of the data that are published on the web bij SPIDER can be found.

Web applications

Web data by nature are well suited for use in (graphic) web applications. Here are examples of simple web pages that use SPIDER data:

SPARQL queries

SPARQL is a query language for RDF-based data. It is similar to SQL, the query language for relational databases. SPARQL can be used to ask questions and to request data. Below are some examples of SPARQL queries. The queries can be copied to one of the Squebi or YASGUI) to play around with, or be executed immediately via the query link that executes the query as a HTTP request.

See currently defined properties of a church building

This query shows all properties defined for things that are defined as a church

HTTP request (click to execute)
▶ SPARQL query (click to expand):
select distinct ?property
where {
	?s a <http://schema.org/Church> .
	?s ?property ?o .
}
  

Get church name labels and coordinates

This query asks for the names of the churches and the coordinates of the point location of the church building in WKT format. Such data could be used to plot locations on a map.

HTTP request (click to execute)
▶ SPARQL query (click to expand):
prefix schema: <http://schema.org/>
prefix dcterms: <http://purl.org/dc/terms/>
prefix locn: <http://www.w3.org/ns/locn#>
prefix geom: <http://data.ign.fr/def/geometrie#>
prefix geosp: <http://www.opengis.net/ont/geosparql#>
select ?name ?wkt
where {
  ?church a schema:Church .
  ?church dcterms:title ?name .
  ?church locn:location ?loc .
  ?loc locn:geometry ?geom .
  ?geom a geom:Point .
  ?geom geom:crs <http://www.opengis.net/def/crs/EPSG/0/28992>.
  ?geom geosp:asWKT ?wkt .
}
  

Show church buildings in Oosterbeek

This query selects church buildings with an address in the town of Oosterbeek.

HTTP request (click to execute)
▶ SPARQL query (click to expand):
prefix locn: <http://www.w3.org/ns/locn#> 
prefix schema: <http://schema.org/>
select ?church ?street ?number
where {
  ?church a schema:Church . 
  ?church locn:address ?address . 
  ?address locn:postName 'Oosterbeek' .
  ?address locn:thoroughfare ?street .
  ?address locn:locatorDesignator ?number .
}
  

Count church buildings by function

This query groups church buildings by their function and counts the number of churches for each function.

HTTP request (click to execute)
▶ SPARQL query (click to expand):
prefix dbo: <http://dbpedia.org/ontology/>
prefix cidoc: <http://www.cidoc-crm.org/rdfs/cidoc_crm_v6.2-draft-2015August.rdfs#>
select ?usage (count(?church) as ?number_of_churches)
where {
  ?church a dbo:Church .
  ?church cidoc:P103_was_intended_for ?usage .
}
group by ?usage