rust_forum/migrations/20241213120203_role_permission.up.sql

6 lines
241 B
MySQL
Raw Normal View History

2024-12-13 16:59:34 +03:00
-- Add up migration script here
CREATE TABLE IF NOT EXISTS "role_permission"(
role_id BIGSERIAL NOT NULL REFERENCES "role"(id),
permission_id BIGSERIAL NOT NULL REFERENCES "permission"(id),
PRIMARY KEY (role_id, permission_id)
);