query-e9cbd59646df5bd21c14ab1e4433621b
diferents valors del qualif P1480 i en quants items/statements es fa servir
SELECT ?P1480value ?P1480valueLabel ?items ?statements WHERE { { SELECT ?P1480value (COUNT(DISTINCT(?item)) as ?items) (COUNT(?value) as ?statements) WHERE { ?prop pq:P1480 ?P1480value . hint:Query hint:optimizer "None" . ?item ?p ?prop . ?property wikibase:claim ?p . ?property wikibase:statementProperty ?ps . ?prop ?ps ?value . } GROUP BY ?P1480value ORDER BY DESC(?items) DESC(?statements) LIMIT 100 } SERVICE wikibase:label { bd:serviceParam wikibase:language "ca,en" } } ORDER BY DESC(?items) DESC(?statements)
Use at
- https://query.wikidata.org/sparql
PREFIX wikibase: <http://wikiba.se/ontology#>
PREFIX pq: <http://www.wikidata.org/prop/qualifier/>
PREFIX bd: <http://www.bigdata.com/rdf#>
#diferents valors del qualif P1480 i en quants items/statements es fa servir
SELECT ?P1480value ?P1480valueLabel ?items ?statements
WHERE
{
{
SELECT ?P1480value (COUNT(DISTINCT(?item)) as ?items) (COUNT(?value) as ?statements)
WHERE
{
?prop pq:P1480 ?P1480value .
?item ?p ?prop .
?property wikibase:claim ?p .
?property wikibase:statementProperty ?ps .
?prop ?ps ?value .
}
GROUP BY ?P1480value
ORDER BY DESC(?items) DESC(?statements)
LIMIT 100
}
SERVICE wikibase:label { bd:serviceParam wikibase:language "ca,en" }
}
ORDER BY DESC(?items) DESC(?statements)
Query found at
graph TD
classDef projected fill:lightgreen;
classDef literal fill:orange;
classDef iri fill:yellow;
v4("?P1480value"):::projected
v5("?item")
v10("?items"):::projected
v6("?p")
v3("?prop")
v7("?property")
v8("?ps")
v10("?statements"):::projected
v9("?value")
c5(["bd:serviceParam"]):::iri
c7(["ca,en"]):::literal
v3 --"pq:P1480"--> v4
v5 -->v6--> v3
v7 --"wikibase:claim"--> v6
v7 --"wikibase:statementProperty"--> v8
v3 -->v8--> v9
bind2[/"count(?item)"/]
v5 --o bind2
bind2 --as--o v10
bind3[/"count(?value)"/]
v9 --o bind3
bind3 --as--o v10
subgraph s1["http://wikiba.se/ontology#label"]
style s1 stroke-width:4px;
c5 --"wikibase:language"--> c7
end