Skip to content
Michael Luggen edited this page Jul 26, 2016 · 7 revisions

General

  • data-filter Filter type (name in paranthese).
  • [data-prefix] Optional, adds a PREFIX if not yet set

Simple Triple Pattern (pattern)

Filters on one specific attribute.

Inputs

  • data-predicate
  • data-object

Filter

?sub @data-predicate @data-object.

Filters Types (filter)

Filters with an operator on a literal.

Inputs

  • data-predicate
  • data-operator [<, >, <=, >=, =, !=]
  • data-literal
  • [data-variable] optional if not set UID is choosen

Filter

?sub @data-predicate @UID.
FILTER(?UID @data-operator @data-literal)

Example

?sub <http://www.w3.org/2006/time#intervalStarts> ?start.
FILTER (?start >= xsd:date('2015-01-01'))

Castings like xsd:date can be added transparently to @data-literal.

Hierarchy (hierarchy)

Input

  • date-subject
  • data-predicate

Filter

@data-subject @data-predicate+ ?sub.

Note the + behind the @data-predicate.

Example

<http://data.staatsarchiv-bs.ch/id/archivalresource/CH-000027-1/pa-633c-a-11> <http://purl.org/dc/terms/hasPart>+ ?sub.

This seems to be extremely slow with current store. (We need to look into optimizations.)

Extension

Including the @data-predicate in the results.

{
  @data-subject @data-predicate+ ?sub.
}
UNION
{
  BIND(@data-predicate AS ?sub)
}

Legend & Comment

@ signifies a value in the filters

Dots matter!