Files
stufflog3/scripts/goose-mysql/20220326173144_stat.sql
T

19 lines
397 B
SQL

-- +goose Up
-- +goose StatementBegin
CREATE TABLE stat (
`id` INT NOT NULL PRIMARY KEY AUTO_INCREMENT,
`scope_id` INT NOT NULL,
`name` VARCHAR(255) NOT NULL,
`description` TEXT NOT NULL,
`weight` FLOAT NOT NULL,
`allowed_amounts` JSON,
UNIQUE (`scope_id`, `name`)
);
-- +goose StatementEnd
-- +goose Down
-- +goose StatementBegin
DROP TABLE IF EXISTS stat;
-- +goose StatementEnd