query-5a8936ba493387e93409167ebf414749
Artists
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
?artworks
?artist ?artistLabel
?example_artwork ?example_artworkLabel
WHERE {
{
SELECT
(COUNT(?artwork) AS ?artworks)
?artist
(SAMPLE(?artwork) AS ?example_artwork)
WHERE {
?artwork wdt:P195 wd:Q2982867 ;
wdt:P170 ?artist .
}
GROUP BY ?artist
} SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". }
}
ORDER BY DESC(?artworks)
Query found at
graph TD
classDef projected fill:lightgreen;
classDef literal fill:orange;
classDef iri fill:yellow;
v3("?artist"):::projected
v2("?artwork")
v4("?artworks"):::projected
v4("?example_artwork"):::projected
c2(["wd:Q2982867"]):::iri
c5(["bd:serviceParam"]):::iri
c7(["#91;AUTO_LANGUAGE#93;,en"]):::literal
v2 --"wdt:P195"--> c2
v2 --"wdt:P170"--> v3
bind2[/"count(?artwork)"/]
v2 --o bind2
bind2 --as--o v4
bind3[/"sample(?artwork)"/]
v2 --o bind3
bind3 --as--o v4
subgraph s1["http://wikiba.se/ontology#label"]
style s1 stroke-width:4px;
c5 --"wikibase:language"--> c7
end