diff options
author | Masaya Tojo <masaya@tojo.tokyo> | 2023-11-11 16:13:41 +0900 |
---|---|---|
committer | Masaya Tojo <masaya@tojo.tokyo> | 2023-11-11 16:13:41 +0900 |
commit | 9c8cbed6cdd725ed1153a260ab0844971b685fbf (patch) | |
tree | 9564f59e51d53764de04e6a685dabee1bf0c9149 /revert/photos.sql | |
parent | 46389b3d0d929d74048a5e2e0431641622f17e1a (diff) |
Change taken_at column type to timestamptz
Diffstat (limited to 'revert/photos.sql')
-rw-r--r-- | revert/photos.sql | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/revert/photos.sql b/revert/photos.sql index 7fb3606..9fccf7e 100644 --- a/revert/photos.sql +++ b/revert/photos.sql @@ -1,9 +1,11 @@ --- Revert photos:photos from pg +-- Deploy photos:photos to pg +-- requires: schema BEGIN; SET search_path to photos; -DROP TABLE photos; +ALTER TABLE photos + ALTER COLUMN taken_at TYPE time USING (taken_at AT TIME ZONE 'Asia/Tokyo')::time; COMMIT; |