Merge branch 'visitor_counter' of https://git.n4vn33t.com/swag/guestbook-ng into visitor_counter

This commit is contained in:
swagg boi 2022-02-09 20:18:23 -05:00
commit b95a1965bd
2 changed files with 10 additions and 0 deletions

1
migrations/8/down.sql Normal file
View file

@ -0,0 +1 @@
DROP TABLE counters;

9
migrations/8/up.sql Normal file
View file

@ -0,0 +1,9 @@
CREATE TABLE IF NOT EXISTS counters (
counter_id SERIAL PRIMARY KEY,
counter_name VARCHAR(64),
counter_value INTEGER,
counter_date TIMESTAMPTZ SET DEFAULT NOW()
);
INSERT INTO counters (counter_name, counter_value)
VALUES ('visitor', 1337);