reshape

Creator
Creator
Seonglae ChoSeonglae Cho
Created
Created
2022 Feb 1 17:40
Editor
Edited
Edited
2022 Feb 1 17:42
Refs
Refs
postgres migration

Creating a table

[[actions]] type = "create_table" name = "users" [[actions.columns]] name = "id" type = "INTEGER" generated = "ALWAYS AS IDENTITY" [[actions.columns]] name = "name" type = "TEXT"
 
 
 
 

Renaming a column

[[actions]] type = "alter_column" table = "users" column = "name" [actions.changes] name = "full_name"
 
 
 
Fabian Lindfors
About six months back, I wrote a post on how to use views in Postgres to encapsulate tables and create a versioned interface to a database. At the end of the post, I mentioned working on a tool to automate zero-downtime migrations using this technique and I've finally released something, albeit experimental.
 
 

Recommendations