Hello all! There is an extrange error in my logfile: update articles set online='t' where id = 391 ; ERROR: duplicate key violates unique constraint "articles_pkey" (the error exists only with this id) I've checked (well, almost imposible) if there was more than one article with this id: select count(*) from articles where id=391 ; count ------- 1 (1 row) Then, I checked the table: Table "public.articles" Column | Type | Modifiers -------------------+------------------------+----------------------------------------------------- id | integer | not null default nextval('"articles_id_seq"'::text) Here is the origin of my problem, I think: "text". "text"?. The "serial" type generate text instead of integer. Really extrange. So, my next query: select id from articles where id like '%391%' ; id ----- 391 391 (2 rows) The problem is easy to solve: delete and re-create the rows. But I would like to know the origin of this error. Any tip? Thanks in advance, Carlos -- [ http://www.improveyourweb.com/ ] web.log.about.web.development ---------------------------(end of broadcast)--------------------------- TIP 8: explain analyze is your friend