query-6c5695a6a4fb8643a9eec580cae8b436
TODO
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 rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX bd: <http://www.bigdata.com/rdf#>
#defaultView:Map
SELECT ?veteran ?veteranLabel ?aitaLabel ?amaLabel ?aita_ ?gatazkaLabel ?coord ?layer ?rgb
WHERE {
{ { select ?veteran ?jaiolekua ?heriotza ?ama ?aita ?coord ?layer ?rgb WHERE {
{ SELECT ?veteran ?jaiolekua ?heriotza ?ama ?aita WHERE {
?veteran wdt:P241 wd:Q11218.
?veteran wdt:P172 wd:Q126756.
?veteran wdt:P19 ?jaiolekua.
?veteran wdt:P20 ?heriotza.
?veteran wdt:P25 ?ama.
?veteran wdt:P22 ?aita.
} } ?ama wdt:P19 ?jaiolekua_ama.
?jaiolekua_ama wdt:P625 ?coord.
BIND("0000FF" as ?rgb)
BIND("Mother" as ?layer)
} }}
UNION
{ { select ?veteran ?jaiolekua ?heriotza ?ama ?aita ?coord ?layer ?rgb WHERE {
{ SELECT ?veteran ?jaiolekua ?heriotza ?ama ?aita WHERE {
?veteran wdt:P241 wd:Q11218.
?veteran wdt:P172 wd:Q126756.
?veteran wdt:P19 ?jaiolekua.
?veteran wdt:P20 ?heriotza.
?veteran wdt:P25 ?ama.
?veteran wdt:P22 ?aita.
} } ?aita wdt:P19 ?jaiolekua_aita.
?jaiolekua_aita wdt:P625 ?coord.
BIND("00FF00" as ?rgb)
BIND("Father" as ?layer)
} }}
UNION
{ { select ?veteran ?jaiolekua ?heriotza ?ama ?aita ?coord ?layer ?rgb WHERE {
{ SELECT ?veteran ?jaiolekua ?heriotza ?ama ?aita WHERE {
?veteran wdt:P241 wd:Q11218.
?veteran wdt:P172 wd:Q126756.
?veteran wdt:P19 ?jaiolekua.
?veteran wdt:P20 ?heriotza.
?veteran wdt:P25 ?ama.
?veteran wdt:P22 ?aita.
} } ?heriotza wdt:P625 ?coord.
BIND("FF0000" as ?rgb)
BIND("veteran place of death" as ?layer)
} }}
UNION
{ { select ?veteran ?jaiolekua ?heriotza ?gatazka ?ama ?aita ?coord ?layer ?rgb WHERE {
{ SELECT ?veteran ?jaiolekua ?heriotza ?ama ?aita WHERE {
?veteran wdt:P241 wd:Q11218.
?veteran wdt:P172 wd:Q126756.
?veteran wdt:P19 ?jaiolekua.
?veteran wdt:P20 ?heriotza.
?veteran wdt:P25 ?ama.
?veteran wdt:P22 ?aita.
} } ?veteran wdt:P607 ?gatazka.
?gatazka wdt:P625 ?coord.
BIND("FFFF00" as ?rgb)
BIND("battle" as ?layer)
} }}
UNION
{ { select ?veteran ?jaiolekua ?heriotza ?ama ?aita ?aita_ ?coord ?layer ?rgb WHERE {
{ SELECT ?veteran ?jaiolekua ?heriotza ?ama ?aita WHERE {
?veteran wdt:P241 wd:Q11218.
?veteran wdt:P172 wd:Q126756.
?veteran wdt:P19 ?jaiolekua.
?veteran wdt:P20 ?heriotza.
?veteran wdt:P25 ?ama.
?veteran wdt:P22 ?aita.
} } ?jaiolekua wdt:P625 ?coord.
BIND("00FFFF" as ?rgb)
BIND("veteran place of birth" as ?layer)
?aita rdfs:label ?aitaL . FILTER(LANG(?aitaL)="en")
BIND(CONCAT("Aita: ",?aitaL) as ?aita_)
} }}
SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". }
}
Query found at
graph TD
classDef projected fill:lightgreen;
classDef literal fill:orange;
classDef iri fill:yellow;
v5("?aita")
v12("?aitaL")
v13("?aita_"):::projected
v4("?ama")
v7("?coord"):::projected
v11("?gatazka")
v3("?heriotza")
v2("?jaiolekua")
v10("?jaiolekua_aita")
v6("?jaiolekua_ama")
v13("?layer"):::projected
v13("?rgb"):::projected
v1("?veteran"):::projected
c4(["wd:Q126756"]):::iri
c14(["bd:serviceParam"]):::iri
c2(["wd:Q11218"]):::iri
c16(["#91;AUTO_LANGUAGE#93;,en"]):::literal
subgraph union0[" Union "]
subgraph union0l[" "]
style union0l fill:#abf,stroke-dasharray: 3 3;
subgraph union1[" Union "]
subgraph union1l[" "]
style union1l fill:#abf,stroke-dasharray: 3 3;
subgraph union2[" Union "]
subgraph union2l[" "]
style union2l fill:#abf,stroke-dasharray: 3 3;
subgraph union3[" Union "]
subgraph union3l[" "]
style union3l fill:#abf,stroke-dasharray: 3 3;
f0[["?aitaL = 'en'"]]
f0 --> v12
v1 --"wdt:P241"--> c2
v1 --"wdt:P172"--> c4
v1 --"wdt:P19"--> v2
v1 --"wdt:P20"--> v3
v1 --"wdt:P25"--> v4
v1 --"wdt:P22"--> v5
v2 --"wdt:P625"--> v7
bind1[/"'00FFFF'"/]
bind1 --as--o v13
bind2[/"'veteran place of birth'"/]
bind2 --as--o v13
v5 --"rdfs:label"--> v12
bind3[/"concat('Aita: ',?aitaL)"/]
v12 --o bind3
bind3 --as--o v13
end
subgraph union3r[" "]
style union3r fill:#abf,stroke-dasharray: 3 3;
v1 --"wdt:P241"--> c2
v1 --"wdt:P172"--> c4
v1 --"wdt:P19"--> v2
v1 --"wdt:P20"--> v3
v1 --"wdt:P25"--> v4
v1 --"wdt:P22"--> v5
v1 --"wdt:P607"--> v11
v11 --"wdt:P625"--> v7
bind4[/"'FFFF00'"/]
bind4 --as--o v13
bind5[/"'battle'"/]
bind5 --as--o v13
end
union3r <== or ==> union3l
end
end
subgraph union2r[" "]
style union2r fill:#abf,stroke-dasharray: 3 3;
v1 --"wdt:P241"--> c2
v1 --"wdt:P172"--> c4
v1 --"wdt:P19"--> v2
v1 --"wdt:P20"--> v3
v1 --"wdt:P25"--> v4
v1 --"wdt:P22"--> v5
v3 --"wdt:P625"--> v7
bind6[/"'FF0000'"/]
bind6 --as--o v13
bind7[/"'veteran place of death'"/]
bind7 --as--o v13
end
union2r <== or ==> union2l
end
end
subgraph union1r[" "]
style union1r fill:#abf,stroke-dasharray: 3 3;
v1 --"wdt:P241"--> c2
v1 --"wdt:P172"--> c4
v1 --"wdt:P19"--> v2
v1 --"wdt:P20"--> v3
v1 --"wdt:P25"--> v4
v1 --"wdt:P22"--> v5
v5 --"wdt:P19"--> v10
v10 --"wdt:P625"--> v7
bind8[/"'00FF00'"/]
bind8 --as--o v13
bind9[/"'Father'"/]
bind9 --as--o v13
end
union1r <== or ==> union1l
end
end
subgraph union0r[" "]
style union0r fill:#abf,stroke-dasharray: 3 3;
v1 --"wdt:P241"--> c2
v1 --"wdt:P172"--> c4
v1 --"wdt:P19"--> v2
v1 --"wdt:P20"--> v3
v1 --"wdt:P25"--> v4
v1 --"wdt:P22"--> v5
v4 --"wdt:P19"--> v6
v6 --"wdt:P625"--> v7
bind10[/"'0000FF'"/]
bind10 --as--o v13
bind11[/"'Mother'"/]
bind11 --as--o v13
end
union0r <== or ==> union0l
end
subgraph s1["http://wikiba.se/ontology#label"]
style s1 stroke-width:4px;
c14 --"wikibase:language"--> c16
end