Re: SQL for CREATE RULE

Поиск
Список
Период
Сортировка
От Alessio Bragadini
Тема Re: SQL for CREATE RULE
Дата
Msg-id 3B52F3C0.AF1B561A@albourne.com
обсуждение исходный текст
Ответ на SQL for CREATE RULE  (Bryan Buchanan <bryanb@webbtide.com.au>)
Список pgsql-general
Bryan Buchanan wrote:

> I have two tables:
>
> journal_master (serial #, account, date, debit $, credit $)
> journal_summary (account, date, debit $, credit $)
>
> each time a transaction occurs, a new journal_master row is
> added, and the cumulative amounts added to the summary table.

You don't need a RULE but a TRIGGER. Check out PostgreSQL's
documentation.

Yes, it's possible and it's similar to your solution.

--
Alessio F. Bragadini        alessio@albourne.com
APL Financial Services        http://village.albourne.com
Nicosia, Cyprus             phone: +357-2-755750

"It is more complicated than you think"
        -- The Eighth Networking Truth from RFC 1925

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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: slow line insert
Следующее
От: Bruce Momjian
Дата:
Сообщение: Auguest Linux Journal