Closed TangoYankee closed 2 weeks ago
This was originally conceived as a big ticket item where we consolidate the errors into a single migration. This was misguided. We should be making these adjustments in small migrations. Going forward, I'm also going to try adding these changes into the endpoint implementation into the tickets that will need them.
Description
There are a few typos and missing features for the capital planning database. We should clean these up as part of the same migration.
Acceptance criteria
captial_commitment
table is renamed tocapital_commitment
#248capitalProjectCategoryEnum
is changed fromITT, Vehicles and Equipment
toITT, Vehicles, and Equipment
(add oxford comma)community_district.li_ft
column type is changed frommultiPointGeom
tomultiPolygonGeom
#247bonus ticket- rename the file so that "community" has the correct number of 'm'sfixed in #286capital_project.mercator_m_pnt
capital_project.mercator_m_poly
community_district.mercator_fill
community_district.mercator_label
city_council_district.mercator_fill
city_council_district.mercator_label
Context
Enum
Postgres does not allow the modification or removal of items from an enum. Instead, we need to do a wholesale replacement of the enum.
Indexing
PostGIS Spatial Indexing is done "using GIST". Drizzle ORM support writing indexes with the "using" keyword. However, drizzle-kit (which generates the migration files) does not. We'll still use drizzle-kit to generate the migration. However, we'll then hand-edit the migration file to use "GIST"
Related work
Blocked by writing the ETL. It's pointing out more errors as data are added. We should get the ETL finished to help identify more errors that we can include in this migration.