pg.ddx.io  pgsql-sql@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Stéphane FILLON <fillons@offratel.nc>
To: pgsql-sql <pgsql-sql@postgresql.org>
To: pgsql-hackers <pgsql-hackers@postgresql.org>
To: pgsql-general <pgsql-general@postgresql.org>
Subject: BUG with UNIQUE clause
Date: Wed, 15 Sep 1999 05:14:15 +1100
Message-ID: <000f01befedd$3f26fda0$a6373ad1@portable> (raw)

Hi,

The UNIQUE constraint doesn't work on a field if I use a DEFAULT clause on a table.

The following table works with UNIQUE constraint:

create table cltclt001(
  tcid int2,
  tcnom text unique
);

but this one accept several same tcnom value:

create table cltclt001(
  tcid int2 default nextval('cltcls001'),
  tcnom text unique
);


What's wrong with my table ?

Thanks in advance.

Stephane FILLON

view thread (3+ messages)  latest in thread

Message-ID: <000f01befedd$3f26fda0$a6373ad1@portable>
Permalink:  ../000f01befedd$3f26fda0$a6373ad1@portable/
Also on:    postgresql.org/message-id/000f01befedd$3f26fda0$a6373ad1@portable

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-sql@postgresql.org
  Cc: fillons@offratel.nc, pgsql-hackers@postgresql.org, pgsql-general@postgresql.org
  Subject: Re: BUG with UNIQUE clause
  In-Reply-To: <000f01befedd$3f26fda0$a6373ad1@portable>
  References: <000f01befedd$3f26fda0$a6373ad1@portable>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox