query-2899ddbcb5e25aca0fabd6be7f365700
Total number of references with values other than Wikimedia projects
Use at
- https://query.wikidata.org/sparql
 
PREFIX wikibase: <http://wikiba.se/ontology#>
PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX wd: <http://www.wikidata.org/entity/>
PREFIX prov: <http://www.w3.org/ns/prov#>
PREFIX pr: <http://www.wikidata.org/prop/reference/>
PREFIX bd: <http://www.bigdata.com/rdf#>
SELECT (COUNT(?statement) AS ?cnt) WHERE {
   {
  SELECT DISTINCT ?item ?itemLabel WHERE {
     {
  SELECT DISTINCT ?item WHERE { [] pr:P143 ?item }
}.
    MINUS { ?item wdt:P31/wdt:P279* wd:Q14827288 }
    MINUS { ?item wdt:P31/wdt:P279* wd:Q63144794 }
    SERVICE wikibase:label { bd:serviceParam wikibase:language 'en' }
  }
}.
  ?statement prov:wasDerivedFrom/pr:P143 ?item .
}
Query found at
graph TD
classDef projected fill:lightgreen;
classDef literal fill:orange;
classDef iri fill:yellow;
  v3("?cnt")
  v1("?item")
  v2("?statement"):::projected 
  a1((" "))
  a2((" "))
  a3((" "))
  a4((" "))
  c7(["bd:serviceParam"]):::iri 
  c5(["wd:Q63144794"]):::iri 
  c4(["wd:Q14827288"]):::iri 
  c9(["en"]):::literal 
  a1 --"pr:P143"-->  v1
  subgraph minus0["MINUS"]
    style minus0 stroke-width:6px,fill:pink,stroke:red;
    v1 --"wdt:P31"-->  a2
    a2 --"wdt:P279"-->  c4
  end
  subgraph minus1["MINUS"]
    style minus1 stroke-width:6px,fill:pink,stroke:red;
    v1 --"wdt:P31"-->  a3
    a3 --"wdt:P279"-->  c5
  end
  subgraph s1["http://wikiba.se/ontology#label"]
    style s1 stroke-width:4px;
    c7 --"wikibase:language"-->  c9
  end
  v2 --"prov:wasDerivedFrom"-->  a4
  a4 --"pr:P143"-->  v1
  bind3[/"count(?statement)"/]
  v2 --o bind3
  bind3 --as--o v3