plpgsql

Поиск
Список
Период
Сортировка
От Jie Liang
Тема plpgsql
Дата
Msg-id 3A3149D2.4E59DA8E@ipinc.com
обсуждение исходный текст
Ответ на currval  (Craig May <craig.may@s2.enthdimension.com.au>)
Ответы Re: plpgsql  (Kovacs Zoltan Sandor <tip@pc10.radnoti-szeged.sulinet.hu>)
Список pgsql-sql
>

Hi, there,

Is there any way to handle exception ( such as cannot insert duplicate key on
a unique index) in
plpgsql function?

I don't want it abort whole transaction instead I want to do something else if
it happened,
but I don't want to use a select stmt first to waste the time.

In Orcale, in plsql we can say,
declare
begin
do something
exception
do something else
end;

How to this exception section in plpgsql????






--
Jie LIANG

Internet Products Inc.

10350 Science Center Drive
Suite 100, San Diego, CA 92121
Office:(858)320-4873

jliang@ipinc.com
www.ipinc.com





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

Предыдущее
От: Stephan Szabo
Дата:
Сообщение: Re: FOREIGN KEY errors.
Следующее
От: "W. van den Akker"
Дата:
Сообщение: How to...