Re: How do I save data and then raise an exception?

Поиск
Список
Период
Сортировка
От Rob Richardson
Тема Re: How do I save data and then raise an exception?
Дата
Msg-id 04A6DB42D2BA534FAC77B90562A6A03DA95EFC@server.rad-con.local
обсуждение исходный текст
Ответ на Re: How do I save data and then raise an exception?  (Raymond O'Donnell <rod@iol.ie>)
Ответы Re: How do I save data and then raise an exception?  ("Scott Marlowe" <scott.marlowe@gmail.com>)
Список pgsql-general
No, because the application first saves the coils and then saves the
charge.  Setting up the foreign key constraint would prevent any coils
from being saved because the charge record would never exist at the time
the coil record was created.

RobR, who would love to hear some of the music in Galway Cathedral!

-----Original Message-----
From: Raymond O'Donnell [mailto:rod@iol.ie]
Sent: Friday, October 03, 2008 10:53 AM
To: Rob Richardson
Cc: pgsql-general@postgresql.org
Subject: Re: [GENERAL] How do I save data and then raise an exception?

On 03/10/2008 14:52, Rob Richardson wrote:
> That's how it should have been done, but it wasn't.  It's too late to
> change it now.  If I make any change to the C++ code, I run into a

But setting up a foreign key constrain is something you do in the
database, not in the app - can't you do that?

Ray.

------------------------------------------------------------------
Raymond O'Donnell, Director of Music, Galway Cathedral, Ireland
rod@iol.ie Galway Cathedral Recitals:
http://www.galwaycathedral.org/recitals
------------------------------------------------------------------

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

Предыдущее
От: Raymond O'Donnell
Дата:
Сообщение: Re: How do I save data and then raise an exception?
Следующее
От: Alvaro Herrera
Дата:
Сообщение: Re: Getting rows in statement-level triggers