aboutsummaryrefslogtreecommitdiff
path: root/migrations/deploy/sessions.sql
diff options
context:
space:
mode:
authorJakob Odersky <jakob@odersky.com>2018-10-27 18:45:06 -0700
committerJakob Odersky <jakob@odersky.com>2018-10-27 18:45:06 -0700
commitde095d377859887352c7380e52ea89bcabf662a0 (patch)
tree6cee6eb17c1977b85e01078e926499b33854047d /migrations/deploy/sessions.sql
downloadbyspel-de095d377859887352c7380e52ea89bcabf662a0.tar.gz
byspel-de095d377859887352c7380e52ea89bcabf662a0.tar.bz2
byspel-de095d377859887352c7380e52ea89bcabf662a0.zip
Initial commit
Diffstat (limited to 'migrations/deploy/sessions.sql')
-rw-r--r--migrations/deploy/sessions.sql13
1 files changed, 13 insertions, 0 deletions
diff --git a/migrations/deploy/sessions.sql b/migrations/deploy/sessions.sql
new file mode 100644
index 0000000..6d0122c
--- /dev/null
+++ b/migrations/deploy/sessions.sql
@@ -0,0 +1,13 @@
+-- Deploy byspel:sessions to sqlite
+-- requires: users
+
+BEGIN;
+
+create table sessions(
+ session_id uuid not null primary key,
+ user_id uuid not null,
+ expires timestamp not null,
+ foreign key (user_id) references users(id) on delete cascade
+);
+
+COMMIT;