triggers in SQL?

Поиск
Список
Период
Сортировка
От Neil Conway
Тема triggers in SQL?
Дата
Msg-id 20000910143639.A6527@klamath.dyndns.org
обсуждение исходный текст
Ответы Re: triggers in SQL?  (Neil Conway <nconway@klamath.dyndns.org>)
Список pgsql-general
I want to write a simple trigger in SQL (i.e. use the trigger to execute
a simple function written in SQL). I'm having difficulty - CREATE TRIGGER
complains if the return type of the procedure is not 'OPAQUE', but CREATE
FUNCTION won't allow me to create SQL functions with a return type of
OPAQUE.

Am I going about this the wrong way? I want to update some data
automatically when new rows are inserted into table A. Should I use a
TRIGGER AFTER INSERT on table A, or is there a better way? The data
that needs to be updated is fairly simple (actually, just 1 or 2
UPDATE queries), which is why I would prefer not to have to load PL/SQL
or write the function in C.

Thanks, and sorry for my newbie-ness.

Neil

--
Neil Conway <neilconway@home.com>
Get my GnuPG key from: http://klamath.dyndns.org/mykey.asc
Encrypted mail welcomed

Whoever you are -- SGI, SCO, HP, or even Microsoft -- most of the smart people
on the planet work somewhere else.
        -- Eric S. Raymond

Вложения

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

Предыдущее
От: lee johnson
Дата:
Сообщение: Re: [Fwd: Re: postgres not allowing new database?]
Следующее
От: lee johnson
Дата:
Сообщение: Re: postgres not allowing new database?