Toggle navigation
Home
New Query
Recent Queries
Discuss
Database tables
Database names
MediaWiki
Wikibase
Replicas browser and optimizer
Login
History
Fork
This query is marked as a draft
This query has been published
by
Gnoeee
.
Toggle Highlighting
SQL
SELECT DISTINCT ?item ?itemLabel ?state ?stateLabel ?start_time ?cases ?cases_time ?recs ?recs_time ?deaths ?deaths_time ?tests ?tests_time WITH { SELECT ?item ?dist ?state ?cases ?cases_time { wd:Q84055514 wdt:P527 ?item. ?item wdt:P276 ?state. OPTIONAL { ?item p:P1603 ?casestmt. ?casestmt ps:P1603 ?cases. OPTIONAL { ?casestmt pq:P585 ?cases_time } } FILTER NOT EXISTS { ?item p:P1603/pq:P585 ?cases_time_ . FILTER(?cases_time_ > ?cases_time) } } } AS %cases WITH { SELECT ?item ?deaths ?deaths_time { wd:Q84055514 wdt:P527 ?item. OPTIONAL { ?item p:P1120 ?deathstmt. ?deathstmt ps:P1120 ?deaths. OPTIONAL { ?deathstmt pq:P585 ?deaths_time } } FILTER NOT EXISTS { ?item p:P1120/pq:P585 ?deaths_time_ . FILTER(?deaths_time_ > ?deaths_time) } } } AS %deaths WITH { SELECT ?item ?recs ?recs_time { wd:Q84055514 wdt:P527 ?item. OPTIONAL { ?item p:P8010 ?recstmt. ?recstmt ps:P8010 ?recs. OPTIONAL { ?recstmt pq:P585 ?recs_time } } FILTER NOT EXISTS { ?item p:P8010/pq:P585 ?recs_time_ . FILTER(?recs_time_ > ?recs_time) } } } AS %recs WITH { SELECT ?item ?tests ?tests_time { wd:Q84055514 wdt:P527 ?item. OPTIONAL { ?item p:P8011 ?testmt. ?testmt ps:P8011 ?tests. OPTIONAL { ?testmt pq:P585 ?tests_time } } FILTER NOT EXISTS { ?item p:P8011/pq:P585 ?tests_time_ . FILTER(?tests_time_ > ?tests_time) } } } AS %tests WHERE { INCLUDE %cases. INCLUDE %deaths. INCLUDE %recs. INCLUDE %tests. OPTIONAL { ?item wdt:P580 ?start_time. } SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". } } ORDER BY DESC (?cases)
By running queries you agree to the
Cloud Services Terms of Use
and you irrevocably agree to release your SQL under
CC0 License
.
Submit Query
Stop Query
All SQL code is licensed under
CC0 License
.
Checking query status...