Callimachus Named Queries use a superset of the SPARQL 1.1 query syntax SELECT form.

As in SPARQL, any prefixes used in the Named Query must be declared using a PREFIX clause. When evaluating, the base IRI of the query is the URI of the Named Query.

Sample named query

PREFIX foaf:    <>
SELECT ?nameX ?nameY ?nickY
  { ?x foaf:knows ?y ;
       foaf:name ?nameX .
    ?y foaf:name ?nameY .
    OPTIONAL { ?y foaf:nick ?nickY }
OFFSET ${ ($pageNumber - 1) * $pageSize } LIMIT ${ $pageSize }