SPARQL Services

Linked Data Finland

Datasets, Graphs, and Services

A dataset in LDF.fi consists of one or more RDF graphs. The graph URI (GRAPH-URI) of a graph (GRAPH) in a dataset (DATASET) is:

GRAPH-URI=http://ldf.fi/DATASET/GRAPH

For example: http://ldf.fi/finlex/laki.

Each dataset is associated with a Fuseki SPARQL service that provides the following more specific service URLs

where SERVICE=ldf.fi/DATASET.

The services can be used with HTTP GET and POST protocols using additional service specific parameters. The SPARQL RDF service description of a service is available at URL:

http://SERVICE/sparql

In below the services are described in more detail.


Download

A graph in a dataset can be downloaded using the HTTP GET/POST pattern:

http://SERVICE/data?graph=GRAPH-URI


Upload

Fuseki Server Management is used for uploading data into graphs and for some other management tasks. However, using this service is restricted to LDF.fi personnel only.


Query

Each dataset DATASET in LDF.fi has a SPARQL endpoint at the address:

http://ldf.fi/DATASET/sparql

A dataset can be queried by using a SPARQL query QUERY as a GET/POST parameter:

http://ldf.fi/DATASET/sparql?query=QUERY

For example:

http://ldf.fi/my-data/sparql?query=DESCRIBE <http://ldf.fi/my-data/p3765>

If different datasets are queried at the same time, then federated SPARQL queries must be used. By LDF convention, the union of the graphs of a dataset are available as a nameless default graph, which means that the URIs of the graphs can be used in queries without naming their graphs.

The Query service (SPARQL endpoint) implements both CORS and JSONP for for making SPARQL queries in JavaScript from other domains than ldf.fi. When using JSONP, the callback function is specified with the URL parameter "callback".

SPARQL Playground

You can investigate datasets by selecting a SPARQL endpoint and submitting a query there.



Endpoint URL:

Update

In addition to SPARQL querying, also SPARQL Update service is supported using HTTP at service URL http://SERVICE/update. However, this service is restricted to LDF.fi maintainers only.