Re: Create Table Unique problem... bug?

Поиск
Список
Период
Сортировка
От Bruno Wolff III
Тема Re: Create Table Unique problem... bug?
Дата
Msg-id 20030528145107.GA4890@wolff.to
обсуждение исходный текст
Ответ на Create Table Unique problem... bug?  (Mauro Bertoli <bertolima@yahoo.it>)
Список pgsql-novice
On Wed, May 28, 2003 at 15:34:41 +0200,
  Mauro Bertoli <bertolima@yahoo.it> wrote:
> INSERT INTO questiontypes (id,flags,label) values
> (2,null,'a');
>
> and re-insert it... I can!!!! Now there are two
> identical row, and UNIQUE??
> I think postgres must occur an error? Is it Ok?

This is how unique constraints work. Any null value is considered as
different from any other null value. If that isn't how you want things
to work, using some value other than null to represent whatever you
are using null to represent.

В списке pgsql-novice по дате отправления:

Предыдущее
От: Dani Oderbolz
Дата:
Сообщение: Re: Create Table Unique problem... bug?
Следующее
От: papapep
Дата:
Сообщение: Re: Inserting data of two other tables [Now deleting ...]