DROP TABLE IF EXISTS dataset; DROP TABLE IF EXISTS category; create table category (id uuid not null, name varchar(255), primary key (id)); create table dataset ( date date, rating float(24) not null, upvotes integer not null, votes integer not null, category_id uuid, id uuid not null, summary varchar(255), author varchar(255), description varchar(200000), title varchar(255), url varchar(2048), terms_of_use varchar(2048), type enum ('API','DATASET'), license varchar(255), primary key (id) ); alter table if exists dataset add constraint FKq6qwq6u473f89h71s7rf97ruy foreign key (category_id) references category;