create table public.taxonomys
(
id serial not null,
parent_id integer,
title_i18n_en varchar(250) not null,
title_i18n_fr varchar(250) not null,
description_i18n_en text,
description_i18n_fr text,
created timestamp not null,
modified timestamp not null,
constraint taxonomys_pkey
primary key (id),
constraint taxonomys_parent_id
foreign key (parent_id) references public.taxonomys
on update cascade on delete cascade
);
create table public.taxonomys_sofwares
(
id serial not null,
taxonomy_id integer not null,
software_id integer not null,
user_id integer,
created timestamp not null,
modified timestamp not null,
constraint taxonomys_sofwares_pkey
primary key (id),
constraint taxonomys_sofwares_taxonomy_id
foreign key (taxonomy_id) references public.taxonomys
on update cascade on delete cascade,
constraint taxonomys_sofwares_software_id
foreign key (software_id) references public.softwares
on update cascade on delete cascade,
constraint taxonomys_sofwares_user_id
foreign key (user_id) references public.users
on update cascade on delete cascade
);