Re: primary key problem

Поиск
Список
Период
Сортировка
От Stephan Szabo
Тема Re: primary key problem
Дата
Msg-id Pine.BSF.4.21.0109100903590.15132-100000@megazone23.bigpanda.com
обсуждение исходный текст
Ответ на primary key problem  (Mohammad Faisal <faisalchouhan@yahoo.com>)
Список pgsql-admin
On Mon, 10 Sep 2001, Mohammad Faisal wrote:

> the primary key in postgreSQL is implemented as unique
> index and the unique index can be deleted and as a
> result the primary key constraints finishes.(oh a
> problem)
> what if i don't want an index on a table then in this
> case how can i implement Primary key constraint.

If you really want to do it yourself, you could write
a trigger procedure that locks the table and then checks to
see if the value is already in the table throwing an error
if it is.  However, that's not going to show up as a primary
key for things that might require it (like foreign keys).

If you want to use the primary key specification, you need to
leave the index alone.



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

Предыдущее
От: "Henshall, Stuart - WCP"
Дата:
Сообщение: Re: FINAL: Multi-User PostgreSQL usage SECURITY
Следующее
От: Leandro Rodrigo Saad Cruz
Дата:
Сообщение: Can't discover database size