Bonjour à tous,
Je rencontre un petit souci sur un INSERT.
Je fais donc un INSERT dans une table contenant une colonne dt_fin défini comme suit :
dt_fin timestamp without time zone NOT NULL DEFAULT '9999-12-31 00:00:00'::timestamp without time zone,
Voici mon INSERT :
INSERT into maTable (id,dt_deb,dt_fin) values (1,'2012-02-17 00:00:00.000000+0100', NULL);
Et j'a l'exception suivante à l'exécution :
null value in column "dt_fin_valid" violates not-null constraint
Pourquoi PostgreSql fait un check du NOT-NULL avant de faire le DEFAULT ?
Merci de votre aide.
Partager