From 9c8cbed6cdd725ed1153a260ab0844971b685fbf Mon Sep 17 00:00:00 2001
From: Masaya Tojo <masaya@tojo.tokyo>
Date: Sat, 11 Nov 2023 16:13:41 +0900
Subject: Change taken_at column type to timestamptz

---
 revert/photos.sql | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

(limited to 'revert/photos.sql')

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;
-- 
cgit v1.2.3

