# SPARQL

## What is RDF?

What can this simple standardized model do for you?

## Calling your own JavaScript functions from SPARQL queries

More Jena arq fun.

## Hidden gems included with Jena’s command line utilities

Lots of ways to manipulate your RDF from the open-source multiplatform tool kit

On page 5 of my book Learning SPARQL I described how the open source RDF processing framework Apache Jena includes command line utilities called arq and sparql that let you run SPARQL queries with a simple command line like this:

## GeoSPARQL queries on OSM Data in GraphDB

Or, Querying geospatial data with SPARQL Part 2

Over a year ago, in Querying geospatial data with SPARQL: Part 1, I described my dream of pulling geospatial data down from Open Street Map, loading it into a local triplestore, and then querying it with queries that conformed to the GeoSPARQL standard. At the time, I tried several triplestores and data sources and never quite got there. When I tried it recently with Ontotext’s free version of GraphDB, it all turned out to be quite easy.

## Using SPARQL do to quick and dirty joins of CSV data

Or data with other delimiters.

I recently needed to join two datasets at work, cross-referencing one property in a spreadsheet with another in a JSON file. I used a combination of jq, perl, sort, uniq, and… I won’t go into details.

## The HTML interface to your SPARQL endpoint is not your SPARQL endpoint

Remember what the 'P' in 'SPARQL' stands for.

Something that happens to me now and then: I’ll hear that an organization with a lot of interesting data (science, music, whatever) makes the data available on a SPARQL endpoint. I send my browser to the URL listed as the SPARQL endpoint and I see a web form. I enter a simple query on the web form to retrieve a few random triples, click the form’s button, and the results of my query appear. Then I enter fancier queries to explore the endpoint’s data.

## Converting CSV to RDF with Tarql

Quick and easy and, if you like, streaming.

I have seen several tools for converting spreadsheets to RDF over the years. They typically try to cover so many different cases that learning how to use them has taken more effort than just writing a short perl script that uses the split() command, so that’s what I usually ended up doing. (Several years ago I did come up with another way that was more of a cute trick with Turtle syntax.)