query-244192a77588d722390013ea026e6a61
Properties had by libraries (apart from instance of (P31))
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 bd: <http://www.bigdata.com/rdf#>
SELECT ?prop ?propLabel (COUNT(?library) AS ?count) WHERE {
?library wdt:P31/wdt:P279? wd:Q7075 ; # libraries or 1st-level subtypes
?p [].
?prop wikibase:directClaim ?p FILTER (?prop != wd:P31)
SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". }
} GROUP BY ?prop ?propLabel
ORDER BY DESC(?count)
Query found at
graph TD
classDef projected fill:lightgreen;
classDef literal fill:orange;
classDef iri fill:yellow;
v5("?count")
v3("?library"):::projected
v4("?p")
v2("?prop"):::projected
a2((" "))
a1((" "))
c3(["wd:Q7075"]):::iri
c7(["bd:serviceParam"]):::iri
c9(["#91;AUTO_LANGUAGE#93;,en"]):::literal
f0[["?prop != 'wd:P31'"]]
f0 --> v2
v3 --"wdt:P31"--> a1
subgraph union0[" Union "]
subgraph union0l[" "]
style union0l fill:#abf,stroke-dasharray: 3 3;
a1 --"wdt:P279"--> c3
end
subgraph union0r[" "]
style union0r fill:#abf,stroke-dasharray: 3 3;
end
union0r <== or ==> union0l
end
v3 -->v4--> a2
v2 --"wikibase:directClaim"--> v4
subgraph s1["http://wikiba.se/ontology#label"]
style s1 stroke-width:4px;
c7 --"wikibase:language"--> c9
end
bind2[/"count(?library)"/]
v3 --o bind2
bind2 --as--o v5