Use pug
This commit is contained in:
1
sql/migrations/patches/20190925000001-users/down.sql
Normal file
1
sql/migrations/patches/20190925000001-users/down.sql
Normal file
@@ -0,0 +1 @@
|
||||
DROP TABLE users;
|
||||
9
sql/migrations/patches/20190925000001-users/up.sql
Normal file
9
sql/migrations/patches/20190925000001-users/up.sql
Normal file
@@ -0,0 +1,9 @@
|
||||
CREATE TABLE users (
|
||||
id integer GENERATED BY DEFAULT AS IDENTITY PRIMARY KEY,
|
||||
email text NOT NULL UNIQUE,
|
||||
encrypted_password text NOT NULL,
|
||||
created_at timestamptz NOT NULL DEFAULT CURRENT_TIMESTAMP,
|
||||
updated_at timestamptz NOT NULL DEFAULT CURRENT_TIMESTAMP
|
||||
);
|
||||
|
||||
CREATE TRIGGER set_users_updated BEFORE UPDATE ON users FOR EACH ROW EXECUTE PROCEDURE set_updated_timestamp();
|
||||
Reference in New Issue
Block a user