Re: error handling

Поиск
Список
Период
Сортировка
От Bruno Wolff III
Тема Re: error handling
Дата
Msg-id 20060427194803.GA990@wolff.to
обсуждение исходный текст
Ответ на error handling  (Verena Ruff <lists@triosolutions.at>)
Ответы Re: error handling
Список pgsql-novice
On Thu, Apr 27, 2006 at 15:29:07 +0200,
  Verena Ruff <lists@triosolutions.at> wrote:
> Hello,
>
> I have a table with an UNIQUE constraint. Is it possible to have
> something like a trigger (or error handler) which is called every time
> a insert statement would break this constraint?  Or in some simple cases
> that this record is just dropped silently, without reporting an error?

Unique constraints are not deferrable in Postgres. It would be possible to
have a function do the insert and trap errors. I don't know if that will
help in your situation though.

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

Предыдущее
От: "Christian Hofmann"
Дата:
Сообщение: Re: Getting the indexes of a table
Следующее
От:
Дата:
Сообщение: 8.1 (win32): partial index not used?