This exercise covers the use of SPARQL and XQuery together in a few different ways. This involves running a series of queries on the BBC news documents and related triples loaded into the database in a previous exercise. This is just one of several tutorials in a sequence, and they should be done in order to gain the most benefit.
Keywords: XQuery, SPARQL, Triple, XML, JSON
Time required: P20M
- Understands how the pattern matching of SPARQL queries can be expressed using functionally equivalent constructs in RDF programming libraries.
- Uses an RDF programming library to serialize RDF data in available syntaxes.
- Uses CONSTRUCT to extract and transform results into a single RDF graph specified by a graph template.
- Uses DISTINCT to ensure solutions in the sequence are unique.
- Uses ORDER BY to define ordering conditions by variable, function call, or expression.