How can I delete a primary or foreign key?

Поиск
Список
Период
Сортировка
От Tibor
Тема How can I delete a primary or foreign key?
Дата
Msg-id 200402201626.19402@newid
обсуждение исходный текст
Ответы Re: How can I delete a primary or foreign key?  (Stephan Szabo <sszabo@megazone.bigpanda.com>)
Re: How can I delete a primary or foreign key?  ("scott.marlowe" <scott.marlowe@ihs.com>)
Список pgsql-general
I am using PostgreSQL 7.4.1 (only through psql)
I know, that the command

ALTER TABLE OFFICES
    DROP PRIMARY KEY (CITY);

and its foreign key equivalent:

ALTER TABLE SALESREPS
    DROP CONSTRAINT
FOREIGN KEY (REP_OFFICE)
    REFERENCES OFFICES;

don't work in PostgreSQL because they are not implemented. However, isn't
there another way of removing them?
I also tried to drop the index associated with the primary key, but it is not
permitted.

Anyone with any idea?
--
Tibor

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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: Slow queries in PL/PGSQL function
Следующее
От: "Gellert, Andre"
Дата:
Сообщение: PHP + Postgres: More than 1000 postmasters produce 70.000 context switches