From 05c22e0093a269f9abdd3239fa53a9ec0c176578 Mon Sep 17 00:00:00 2001 From: lyx0 <66651385+lyx0@users.noreply.github.com> Date: Sat, 4 Mar 2023 19:18:15 +0000 Subject: [PATCH] add migration for lastfm_users --- migrations/000005_create_lastfm_table.down.sql | 1 + migrations/000005_create_lastfm_table.up.sql | 10 ++++++++++ 2 files changed, 11 insertions(+) create mode 100644 migrations/000005_create_lastfm_table.down.sql create mode 100644 migrations/000005_create_lastfm_table.up.sql diff --git a/migrations/000005_create_lastfm_table.down.sql b/migrations/000005_create_lastfm_table.down.sql new file mode 100644 index 0000000..1e5e721 --- /dev/null +++ b/migrations/000005_create_lastfm_table.down.sql @@ -0,0 +1 @@ +DROP TABLE IF EXISTS lastfm_users; diff --git a/migrations/000005_create_lastfm_table.up.sql b/migrations/000005_create_lastfm_table.up.sql new file mode 100644 index 0000000..7676952 --- /dev/null +++ b/migrations/000005_create_lastfm_table.up.sql @@ -0,0 +1,10 @@ +CREATE TABLE IF NOT EXISTS lastfm_users ( + id bigserial PRIMARY KEY, + twitch_login text UNIQUE NOT NULL, + twitch_id text NOT NULL, + lastfm_username text NOT NULL +); + +INSERT INTO lastfm_users (twitch_login,twitch_id,lastfm_username) VALUES + ('nourylul','31437432','nouryqt'); +