home / timezones

Find time zones that intersect a country

Custom SQL query (hide)

with country as (
  select
    geometry
  from
    countries
  where
    admin = :country
)
select
  timezones.tzid,
  simplify(timezones.geometry, 0.05) as geometry
from
  timezones,
  country
where
  timezones.id in (
    select
      SpatialIndex.rowid
    from
      SpatialIndex,
      country
    where
      f_table_name = 'timezones'
      and search_frame = country.geometry
  )
  and intersects(timezones.geometry, country.geometry) = 1

Query parameters

0 results

Powered by Datasette · Queries took 7.686ms