query-9868b4c9f2909655224b5355c1f5458a
Image grid based on multiple image properties have multiple image-related properties, and I am trying to build an image grid based on that, for which I have the following query: (Q1033)Nigeria Items like
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/>
#defaultView:ImageGrid
SELECT * WHERE {
VALUES ?item {wd:Q1033}
?property wdt:P31 wd:Q18610173 .
?property wdt:P31 wd:Q26940804 .
?property a wikibase:Property;
wikibase:statementValue ?psv ;
wikibase:claim ?p.
?item ?p ?Image1 .
# ?item ?property ?Image2 . # no results
# ?item [wdt:P31 wd:Q18610173] ?Image3 . # syntax error
# ?item ?psv ?Image4 . # no results
# ?Image1 ?psv ?Image5 . # no results
}
Query found at
graph TD
classDef projected fill:lightgreen;
classDef literal fill:orange;
classDef iri fill:yellow;
v5("?Image1"):::projected
v1("?item"):::projected
v4("?p"):::projected
v2("?property"):::projected
v3("?psv"):::projected
c5(["wikibase:Property"]):::iri
c3(["wd:Q26940804"]):::iri
c2(["wd:Q18610173"]):::iri
bind0[/VALUES ?item/]
bind0-->v1
bind00(["wd:Q1033"])
bind00 --> bind0
v2 --"wdt:P31"--> c2
v2 --"wdt:P31"--> c3
v2 --"a"--> c5
v2 --"wikibase:statementValue"--> v3
v2 --"wikibase:claim"--> v4
v1 -->v4--> v5