go-project-template/db/migrations/001_init.sql

14 lines
330 B
MySQL
Raw Permalink Normal View History

2024-05-05 22:10:32 +00:00
-- +goose Up
-- +goose StatementBegin
2024-07-25 05:13:23 +00:00
CREATE TABLE users (
id SERIAL PRIMARY KEY,
idp_sub VARCHAR(36) UNIQUE NOT NULL, -- is this long enough for other IDPs? Keycloak gives a UUID
username VARCHAR(50) NOT NULL
);
2024-05-05 22:10:32 +00:00
-- +goose StatementEnd
-- +goose Down
-- +goose StatementBegin
2024-07-25 05:13:23 +00:00
DROP TABLE users;
2024-05-05 22:10:32 +00:00
-- +goose StatementEnd