query-33fc132d8396c2ba9d45de93787e0ddc

rq turtle/ttl

"Chemistry" as object of Wikidata statements. SELECT ?p ?pLabel (COUNT(?s) AS ?count) WHERE { ?s ?p ?o. ?o wdt:P279* wd:Q2329 . FILTER(?p NOT IN (wdt:P31,schema:about,p:statement\/P31, wdt:P279, p:statement\/P279))

SERVICE wikibase:label { bd:serviceParam wikibase:language "en" } } GROUP BY ?p ?pLabel

Use at

PREFIX wikibase: <http://wikiba.se/ontology#>
PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX wd: <http://www.wikidata.org/entity/>
PREFIX schema: <http://schema.org/>
PREFIX p: <http://www.wikidata.org/prop/>
PREFIX bd: <http://www.bigdata.com/rdf#>
#"Chemistry" as object of Wikidata statements.
SELECT ?p ?pLabel (COUNT(?s) AS ?count) 
WHERE { ?s ?p ?o. 
       ?o wdt:P279* wd:Q2329 . 
FILTER(?p NOT IN (wdt:P31,schema:about,p:statement\/P31, wdt:P279, p:statement\/P279)) 

SERVICE wikibase:label { bd:serviceParam wikibase:language "en" }
}
GROUP BY ?p ?pLabel

Query found at

graph TD classDef projected fill:lightgreen; classDef literal fill:orange; classDef iri fill:yellow; v4("?count") v3("?o") v1("?p"):::projected v2("?s"):::projected c6(["wd:Q2329"]):::iri c8(["bd:serviceParam"]):::iri c10(["en"]):::literal f0[["?p != 'p:direct/P31'?p != 'schema:about'?p != 'p:statement/P31'?p != 'p:direct/P279'?p != 'p:statement/P279'"]] f0 --> v1 v2 -->v1--> v3 v3 --"p:direct/P279"--> c6 subgraph s1["http://wikiba.se/ontology#label"] style s1 stroke-width:4px; c8 --"wikibase:language"--> c10 end bind2[/"count(?s)"/] v2 --o bind2 bind2 --as--o v4