DROP TABLE IF EXISTS role;

-- DROP SEQUENCE IF EXISTS role_role_id_seq;
-- CREATE SEQUENCE role_role_id_seq;

CREATE TABLE role (
  "role_id" int PRIMARY KEY GENERATED BY DEFAULT AS IDENTITY, -- SERIAL PRIMARY KEY
  "name" varchar(191) NOT NULL,
  "display_name" varchar(191) NOT NULL,
  "permissions" text NOT NULL
  -- PRIMARY KEY("role_id")
);

SELECT setval('role_role_id_seq', 11, true); -- last inserted id by sample data
