gojuno / lostgis

BSD 3-Clause "New" or "Revised" License
26 stars 5 forks source link

Make a PostgreSQL EXTENSION from OSM opening_hours type and functions? #9

Open sfkeller opened 4 years ago

sfkeller commented 4 years ago

Hi Darafei and Zverik

I'm interested in processing OpenStreetMap data and just stumbled over this OSM opening_hours code https://github.com/gojuno/lostgis/blob/master/sql/types/type_opening_hours.sql via https://pgxn.org/dist/lostgis/doc/lostgis.html#opening_hours

  1. Are there any updates on these PostgreSQL types and functions?
  2. How about extracting these types and functions to a separate and self-contained PostgreSQL EXTENSION?

P.S. This is isn't actually only a feature request. It's also a note to you (and a bookmark to self) as I'm always looking for self-contained projects suitable for students and interns.

Komzpa commented 4 years ago

Hi Stefan,

  1. Likely no. This was done to support toll cost calculation for juno backend and never aimed to be a full implementation, just a subset to support billing. It got rewritten from SQL afterwards, before the bankrupcy of Juno.

  2. go on. most of interesting things went into PostGIS itself (the STSafe* things) or Postgres itself (like the jsonb casts) or sparked discussions to get into MobilityDB. If you can save opening hours code to also be used that will be great.