/**
 * @author Sbarthon
 * @date 04/05/2022
 * @version 1.0.0
 * @project SIEau
 * @table agri_tour_eau_plages
 */
# --- !Ups

create table agri_tour_eau_plages (
idPlage bigint,
annee integer,
heureDebut varchar,
nbPlages integer,
commentaires text,
loginmaj character varying(50),
datemaj timestamp without time zone);

create unique index pk_agri_tour_eau_plages on agri_tour_eau_plages (idPlage, annee);

alter table agri_tour_eau add column idPlage bigint;
alter table agri_tour_eau add column annee bigint;

create unique index pk_agri_tour_eau on agri_tour_eau (codeExploitation, codeinstallation, idmateriel, annee);


# --- !Downs

