added more db stuff, NOT WORKING
This commit is contained in:
0
migrations/posts/down.sql
Normal file
0
migrations/posts/down.sql
Normal file
11
migrations/posts/up.sql
Normal file
11
migrations/posts/up.sql
Normal file
@@ -0,0 +1,11 @@
|
||||
|
||||
CREATE TABLE IF NOT EXISTS Posts (
|
||||
id UUID NOT NULL UNIQUE,
|
||||
title TEXT NOT NULL,
|
||||
descr TEXT NOT NULL,
|
||||
img_url TEXT NOT NULL,
|
||||
origin_url TEXT NOT NULL,
|
||||
original_request JSON NOT NULL,
|
||||
posted_on TIMESTAMP NOT NULL
|
||||
PRIMARY KEY (id)
|
||||
)
|
||||
0
migrations/tokens/down.sql
Normal file
0
migrations/tokens/down.sql
Normal file
7
migrations/tokens/up.sql
Normal file
7
migrations/tokens/up.sql
Normal file
@@ -0,0 +1,7 @@
|
||||
|
||||
CREATE TABLE IF NOT EXISTS Tokens (
|
||||
token TEXT NOT NULL UNIQUE,
|
||||
owner_id UUID NOT NULL,
|
||||
permissions BIGINT NOT NULL,
|
||||
PRIMARY KEY (token)
|
||||
)
|
||||
@@ -1,4 +1,4 @@
|
||||
-- Your SQL goes here
|
||||
|
||||
CREATE TABLE IF NOT EXISTS Users (
|
||||
id UUID NOT NULL UNIQUE,
|
||||
email TEXT NOT NULL,
|
||||
Reference in New Issue
Block a user