sparql-examples

A set of SPARQL examples

View the Project on GitHub Adafede/sparql-examples

wd_maintenance_nps_few_statements

rq turtle/ttl

NPs with very few statements.

Use at


PREFIX p: <http://www.wikidata.org/prop/>
PREFIX wikibase: <http://wikiba.se/ontology#>
#title: NPs with very few statements
SELECT DISTINCT ?structure ?count WHERE {
  VALUES ?min_val { 20 }
  ?structure p:P703 [];
    p:P235 [];
    wikibase:statements ?count.
  FILTER(?count < ?min_val )
}
ORDER BY (?count)


graph TD
classDef projected fill:lightgreen;
classDef literal fill:orange;
classDef iri fill:yellow;
  v1("?count"):::projected 
  v3("?min_val")
  v3("?structure"):::projected 
  a1((" "))
  a2((" "))
  f0[["?count < ?min_val"]]
  f0 --> v1
  f0 --> v3
  bind1[/VALUES ?min_val/]
  bind1-->v3
  bind10(["20^^xsd:integer"])
  bind10 --> bind1
  v3 --"p:P703"-->  a1
  v3 --"p:P235"-->  a2
  v3 --"wikibase:statements"-->  v1