query-6a569eaccb467dab942a2c75d1fa7c6a
Look up the Wikipedia articles for artworks from a specific collectionVersion 1
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 schema: <http://schema.org/>
PREFIX bd: <http://www.bigdata.com/rdf#>
SELECT ?work ?workLabel ?creatorLabel ?lang ?article WHERE {
?work wdt:P195 wd:Q1471477 .
SERVICE wikibase:label { bd:serviceParam wikibase:language "nl,en,fr,uk" . }
OPTIONAL { ?work wdt:P170 ?creator . }
?article schema:about ?work; schema:inLanguage ?lang .
FILTER(!REGEX(str(?article),'commons')) #remove this filter if you want to see the commons categories as well
}
ORDER BY ?work ?lang
Query found at
graph TD
classDef projected fill:lightgreen;
classDef literal fill:orange;
classDef iri fill:yellow;
v3("?article"):::projected
v4("?creator")
v2("?lang"):::projected
v1("?work"):::projected
c5(["bd:serviceParam"]):::iri
c3(["wd:Q1471477"]):::iri
c7(["nl,en,fr,uk"]):::literal
f0[["not regex(str(?article),'commons')"]]
f0 --> v3
v1 --"wdt:P195"--> c3
subgraph s1["http://wikiba.se/ontology#label"]
style s1 stroke-width:4px;
c5 --"wikibase:language"--> c7
end
subgraph optional0["(optional)"]
style optional0 fill:#bbf,stroke-dasharray: 5 5;
v1 -."wdt:P170".-> v4
end
v3 --"schema:about"--> v1
v3 --"schema:inLanguage"--> v2