query-edf9923180d01d5bc3a8795a54d59a2c
TODO
Use at
- https://query.wikidata.org/sparql
PREFIX wikibase: <http://wikiba.se/ontology#>
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#>
SELECT ?item ?itemLabel ?start_time ?start_time2 WHERE {
?item p:P1435 ?stat .
?stat ps:P1435 wd:Q19558910.
optional { ?stat pq:P580 ?start_time. }
?item p:P1435 ?stat2 .
?stat2 ps:P1435 wd:Q19558910.
optional { ?stat2 pq:P580 ?start_time2. }
filter(str(?stat) < str(?stat2))
SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE]". }
}
Query found at
graph TD
classDef projected fill:lightgreen;
classDef literal fill:orange;
classDef iri fill:yellow;
v3("?item"):::projected
v4("?start_time"):::projected
v5("?start_time2"):::projected
v1("?stat")
v2("?stat2")
c3(["wd:Q19558910"]):::iri
c6(["bd:serviceParam"]):::iri
c8(["#91;AUTO_LANGUAGE#93;"]):::literal
f0[["str(?stat) < str(?stat2)"]]
f0 --> v1
f0 --> v2
v3 --"p:P1435"--> v1
v1 --"p:statement/P1435"--> c3
subgraph optional0["(optional)"]
style optional0 fill:#bbf,stroke-dasharray: 5 5;
v1 -."p:qualifier/P580".-> v4
end
v3 --"p:P1435"--> v2
v2 --"p:statement/P1435"--> c3
subgraph optional1["(optional)"]
style optional1 fill:#bbf,stroke-dasharray: 5 5;
v2 -."p:qualifier/P580".-> v5
end
subgraph s1["http://wikiba.se/ontology#label"]
style s1 stroke-width:4px;
c6 --"wikibase:language"--> c8
end