query-aba9efa12a74e06319daef750e5c4db9
Buildings on Wenceslas Square
Use at
- https://query.wikidata.org/sparql
PREFIX xsd: <http://www.w3.org/2001/XMLSchema#>
PREFIX wikibase: <http://wikiba.se/ontology#>
PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX wd: <http://www.wikidata.org/entity/>
PREFIX ps: <http://www.wikidata.org/prop/statement/>
PREFIX pq: <http://www.wikidata.org/prop/qualifier/>
PREFIX p: <http://www.wikidata.org/prop/>
PREFIX bd: <http://www.bigdata.com/rdf#>
#defaultView:ImageGrid{"hide":["?img"]}
SELECT DISTINCT ?item ?itemLabel ?streetno ?cons ?img
WHERE
{
?item wdt:P31/wdt:P279* wd:Q41176.
?item p:P669 ?street .
?street ps:P669 wd:Q847613 .
OPTIONAL { ?street pq:P670 ?streetno } .
OPTIONAL { ?item wdt:P4856 ?cons } .
OPTIONAL { ?item wdt:P18 ?img } .
SERVICE wikibase:label { bd:serviceParam wikibase:language "cs,en" } .
}
ORDER BY xsd:integer(?streetno)
Query found at
graph TD
classDef projected fill:lightgreen;
classDef literal fill:orange;
classDef iri fill:yellow;
v4("?cons"):::projected
v5("?img"):::projected
v2("?item"):::projected
v3("?street")
v1("?streetno"):::projected
a1((" "))
c3(["wd:Q41176"]):::iri
c13(["cs,en"]):::literal
c6(["wd:Q847613"]):::iri
c11(["bd:serviceParam"]):::iri
v2 --"p:direct/P31"--> a1
a1 --"p:direct/P279"--> c3
v2 --"p:P669"--> v3
v3 --"p:statement/P669"--> c6
subgraph optional0["(optional)"]
style optional0 fill:#bbf,stroke-dasharray: 5 5;
v3 -."p:qualifier/P670".-> v1
end
subgraph optional1["(optional)"]
style optional1 fill:#bbf,stroke-dasharray: 5 5;
v2 -."p:direct/P4856".-> v4
end
subgraph optional2["(optional)"]
style optional2 fill:#bbf,stroke-dasharray: 5 5;
v2 -."p:direct/P18".-> v5
end
subgraph s1["http://wikiba.se/ontology#label"]
style s1 stroke-width:4px;
c11 --"wikibase:language"--> c13
end