query-7002733acdd196fbe164f8a3795d2541
End date of by more than 1 day:
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#>
SELECT ?senLabel ?stmt ?prop (?oldEnd AS ?lastChecked) ( ?newEnd AS ?wikiLastChecked ) (?end AS ?current) WHERE {
VALUES (?sen ?seat ?term ?oldEnd ?newEnd) {
( wd:Q376645 wd:Q101498902 wd:Q347346 "1992-11-10T00:00:00Z"^^xsd:dateTime "1992-11-03T00:00:00Z"^^xsd:dateTime )
( wd:Q1376165 wd:Q101498859 wd:Q4632990 "1845-05-01T00:00:00Z"^^xsd:dateTime UNDEF )
( wd:Q453709 wd:Q101499040 wd:Q3596857 "1996-11-05T00:00:00Z"^^xsd:dateTime "1996-11-06T00:00:00Z"^^xsd:dateTime )
( wd:Q202950 wd:Q101498973 wd:Q2573610 "1797-07-10T00:00:00Z"^^xsd:dateTime "1797-12-10T00:00:00Z"^^xsd:dateTime )
( wd:Q1374474 wd:Q101499049 wd:Q4638577 "1881-03-07T00:00:00Z"^^xsd:dateTime UNDEF )
( wd:Q1374474 wd:Q101499049 wd:Q4638577 "1883-03-03T00:00:00Z"^^xsd:dateTime UNDEF )
( wd:Q1672420 wd:Q101499049 wd:Q4643615 "1942-11-17T00:00:00Z"^^xsd:dateTime "1942-11-03T00:00:00Z"^^xsd:dateTime )
( wd:Q2059697 wd:Q101499057 wd:Q4646042 "1978-12-14T00:00:00Z"^^xsd:dateTime "1978-12-12T00:00:00Z"^^xsd:dateTime )
( wd:Q723444 wd:Q101498869 wd:Q4646187 "1982-12-27T00:00:00Z"^^xsd:dateTime "1982-12-20T00:00:00Z"^^xsd:dateTime )
( wd:Q457691 wd:Q101498984 wd:Q2395126 "1800-08-01T00:00:00Z"^^xsd:dateTime UNDEF )
( wd:Q711521 wd:Q101498865 wd:Q4635921 "1861-03-08T00:00:00Z"^^xsd:dateTime "1861-03-06T00:00:00Z"^^xsd:dateTime )
( wd:Q932530 wd:Q101498988 wd:Q2573610 "1797-10-01T00:00:00Z"^^xsd:dateTime UNDEF )
( wd:Q371165 wd:Q101498988 wd:Q1906490 "1801-05-06T00:00:00Z"^^xsd:dateTime "1801-03-05T00:00:00Z"^^xsd:dateTime )
( wd:Q880519 wd:Q101498988 wd:Q4547180 "1807-09-01T00:00:00Z"^^xsd:dateTime UNDEF )
( wd:Q883164 wd:Q101498880 wd:Q4550107 "1816-11-01T00:00:00Z"^^xsd:dateTime UNDEF )
( wd:Q925743 wd:Q101499000 wd:Q3556780 "1994-12-01T00:00:00Z"^^xsd:dateTime "1994-12-02T00:00:00Z"^^xsd:dateTime )
( wd:Q11815 wd:Q101498883 wd:Q223336 "1794-05-27T00:00:00Z"^^xsd:dateTime "1794-03-27T00:00:00Z"^^xsd:dateTime )
( wd:Q1355895 wd:Q101498993 wd:Q4635921 "1861-03-28T00:00:00Z"^^xsd:dateTime "1861-07-11T00:00:00Z"^^xsd:dateTime )
}
# VALUES ?sen { wd:Q1148970 }
?sen p:P39 ?stmt;
wdt:P31 wd:Q5.
?stmt ps:P39 wd:Q4416090;
pq:P768 ?seat;
pq:P2937 ?term.
OPTIONAL { ?stmt pq:P582 ?end. }
BIND("P582" AS ?prop)
FILTER( ?oldEnd = ?end )
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;
v11("?current")
v2("?end"):::projected
v9("?lastChecked")
v6("?newEnd"):::projected
v6("?oldEnd"):::projected
v8("?prop"):::projected
v4("?seat")
v3("?sen")
v7("?stmt"):::projected
v5("?term")
v10("?wikiLastChecked")
c10(["bd:serviceParam"]):::iri
c5(["wd:Q4416090"]):::iri
c3(["wd:Q5"]):::iri
c12(["#91;AUTO_LANGUAGE#93;,en"]):::literal
f0[["?oldEnd = ?end"]]
f0 --> v6
f0 --> v2
bind1[/VALUES ?newEnd ?oldEnd ?seat ?sen ?term/]
bind1-->v3
bind1-->v4
bind1-->v5
bind1-->v6
bind1-->v6
bind10(["wd:Q376645"])
bind10 --> bind1
bind11(["wd:Q101498902"])
bind11 --> bind1
bind12(["wd:Q347346"])
bind12 --> bind1
bind13(["1992-11-10T00:00:00Z^^xsd:dateTime"])
bind13 --> bind1
bind14(["1992-11-03T00:00:00Z^^xsd:dateTime"])
bind14 --> bind1
bind15(["wd:Q1376165"])
bind15 --> bind1
bind16(["wd:Q101498859"])
bind16 --> bind1
bind17(["wd:Q4632990"])
bind17 --> bind1
bind18(["1845-05-01T00:00:00Z^^xsd:dateTime"])
bind18 --> bind1
bind19([ERROR: Bad value])
bind19 --> bind1
bind110(["wd:Q453709"])
bind110 --> bind1
bind111(["wd:Q101499040"])
bind111 --> bind1
bind112(["wd:Q3596857"])
bind112 --> bind1
bind113(["1996-11-05T00:00:00Z^^xsd:dateTime"])
bind113 --> bind1
bind114(["1996-11-06T00:00:00Z^^xsd:dateTime"])
bind114 --> bind1
bind115(["wd:Q202950"])
bind115 --> bind1
bind116(["wd:Q101498973"])
bind116 --> bind1
bind117(["wd:Q2573610"])
bind117 --> bind1
bind118(["1797-07-10T00:00:00Z^^xsd:dateTime"])
bind118 --> bind1
bind119(["1797-12-10T00:00:00Z^^xsd:dateTime"])
bind119 --> bind1
bind120(["wd:Q1374474"])
bind120 --> bind1
bind121(["wd:Q101499049"])
bind121 --> bind1
bind122(["wd:Q4638577"])
bind122 --> bind1
bind123(["1881-03-07T00:00:00Z^^xsd:dateTime"])
bind123 --> bind1
bind124([ERROR: Bad value])
bind124 --> bind1
bind125(["wd:Q1374474"])
bind125 --> bind1
bind126(["wd:Q101499049"])
bind126 --> bind1
bind127(["wd:Q4638577"])
bind127 --> bind1
bind128(["1883-03-03T00:00:00Z^^xsd:dateTime"])
bind128 --> bind1
bind129([ERROR: Bad value])
bind129 --> bind1
bind130(["wd:Q1672420"])
bind130 --> bind1
bind131(["wd:Q101499049"])
bind131 --> bind1
bind132(["wd:Q4643615"])
bind132 --> bind1
bind133(["1942-11-17T00:00:00Z^^xsd:dateTime"])
bind133 --> bind1
bind134(["1942-11-03T00:00:00Z^^xsd:dateTime"])
bind134 --> bind1
bind135(["wd:Q2059697"])
bind135 --> bind1
bind136(["wd:Q101499057"])
bind136 --> bind1
bind137(["wd:Q4646042"])
bind137 --> bind1
bind138(["1978-12-14T00:00:00Z^^xsd:dateTime"])
bind138 --> bind1
bind139(["1978-12-12T00:00:00Z^^xsd:dateTime"])
bind139 --> bind1
bind140(["wd:Q723444"])
bind140 --> bind1
bind141(["wd:Q101498869"])
bind141 --> bind1
bind142(["wd:Q4646187"])
bind142 --> bind1
bind143(["1982-12-27T00:00:00Z^^xsd:dateTime"])
bind143 --> bind1
bind144(["1982-12-20T00:00:00Z^^xsd:dateTime"])
bind144 --> bind1
bind145(["wd:Q457691"])
bind145 --> bind1
bind146(["wd:Q101498984"])
bind146 --> bind1
bind147(["wd:Q2395126"])
bind147 --> bind1
bind148(["1800-08-01T00:00:00Z^^xsd:dateTime"])
bind148 --> bind1
bind149([ERROR: Bad value])
bind149 --> bind1
bind150(["wd:Q711521"])
bind150 --> bind1
bind151(["wd:Q101498865"])
bind151 --> bind1
bind152(["wd:Q4635921"])
bind152 --> bind1
bind153(["1861-03-08T00:00:00Z^^xsd:dateTime"])
bind153 --> bind1
bind154(["1861-03-06T00:00:00Z^^xsd:dateTime"])
bind154 --> bind1
bind155(["wd:Q932530"])
bind155 --> bind1
bind156(["wd:Q101498988"])
bind156 --> bind1
bind157(["wd:Q2573610"])
bind157 --> bind1
bind158(["1797-10-01T00:00:00Z^^xsd:dateTime"])
bind158 --> bind1
bind159([ERROR: Bad value])
bind159 --> bind1
bind160(["wd:Q371165"])
bind160 --> bind1
bind161(["wd:Q101498988"])
bind161 --> bind1
bind162(["wd:Q1906490"])
bind162 --> bind1
bind163(["1801-05-06T00:00:00Z^^xsd:dateTime"])
bind163 --> bind1
bind164(["1801-03-05T00:00:00Z^^xsd:dateTime"])
bind164 --> bind1
bind165(["wd:Q880519"])
bind165 --> bind1
bind166(["wd:Q101498988"])
bind166 --> bind1
bind167(["wd:Q4547180"])
bind167 --> bind1
bind168(["1807-09-01T00:00:00Z^^xsd:dateTime"])
bind168 --> bind1
bind169([ERROR: Bad value])
bind169 --> bind1
bind170(["wd:Q883164"])
bind170 --> bind1
bind171(["wd:Q101498880"])
bind171 --> bind1
bind172(["wd:Q4550107"])
bind172 --> bind1
bind173(["1816-11-01T00:00:00Z^^xsd:dateTime"])
bind173 --> bind1
bind174([ERROR: Bad value])
bind174 --> bind1
bind175(["wd:Q925743"])
bind175 --> bind1
bind176(["wd:Q101499000"])
bind176 --> bind1
bind177(["wd:Q3556780"])
bind177 --> bind1
bind178(["1994-12-01T00:00:00Z^^xsd:dateTime"])
bind178 --> bind1
bind179(["1994-12-02T00:00:00Z^^xsd:dateTime"])
bind179 --> bind1
bind180(["wd:Q11815"])
bind180 --> bind1
bind181(["wd:Q101498883"])
bind181 --> bind1
bind182(["wd:Q223336"])
bind182 --> bind1
bind183(["1794-05-27T00:00:00Z^^xsd:dateTime"])
bind183 --> bind1
bind184(["1794-03-27T00:00:00Z^^xsd:dateTime"])
bind184 --> bind1
bind185(["wd:Q1355895"])
bind185 --> bind1
bind186(["wd:Q101498993"])
bind186 --> bind1
bind187(["wd:Q4635921"])
bind187 --> bind1
bind188(["1861-03-28T00:00:00Z^^xsd:dateTime"])
bind188 --> bind1
bind189(["1861-07-11T00:00:00Z^^xsd:dateTime"])
bind189 --> bind1
v3 --"p:P39"--> v7
v3 --"p:direct/P31"--> c3
v7 --"p:statement/P39"--> c5
v7 --"p:qualifier/P768"--> v4
v7 --"p:qualifier/P2937"--> v5
subgraph optional0["(optional)"]
style optional0 fill:#bbf,stroke-dasharray: 5 5;
v7 -."p:qualifier/P582".-> v2
end
bind2[/"'P582'"/]
bind2 --as--o v8
subgraph s1["http://wikiba.se/ontology#label"]
style s1 stroke-width:4px;
c10 --"wikibase:language"--> c12
end
bind3[/"?oldEnd"/]
v6 --o bind3
bind3 --as--o v9
bind4[/"?newEnd"/]
v6 --o bind4
bind4 --as--o v10
bind5[/"?end"/]
v2 --o bind5
bind5 --as--o v11