Jump to content

Template:Query link/doc

From Wikisource

Usage

[edit]

Produce a link to the Wikidata Query Service with a given SPARQL query

  • query the query SPARQL
  • label optional link label

Example

{{query link
 | link = All subclasses of "Written Work"
 |query=
#All subclasses of "Written Work"
SELECT ?subclass ?desc WHERE {
  ?subclass (wdt:P279+) wd:Q47461344.
  OPTIONAL {
    ?subclass rdfs:label ?desc.
    FILTER((LANG(?desc)) = "en")
  }
}
}}

Go to query page

See also

[edit]