Sum of two rows

Поиск
Список
Период
Сортировка
От Alexander Pucher
Тема Sum of two rows
Дата
Msg-id 3E6C62B9.2070908@atlas.gis.univie.ac.at
обсуждение исходный текст
Ответы Re: Sum of two rows  (Manfred Koizar <mkoi-pg@aon.at>)
Список pgsql-novice
Hi,

this might be an obvious thing, but still I'm biting on this for some time:

Let's pretend  I want to have a table with 3 columns.
The first and second should each hold an integer value, the third should
hold the sum of column1 + column2 as an integer.

The idea behind this table should be that the sum is automatically
updated, each time I change one of the values in either of the first two
columns.

Best regards,
alex

--
________________________________________________________

Institut fuer Geographie und Regionalforschung
Universitaet Wien
Kartografie und Geoinformation

Departement of Geography and Regional Research
University of Vienna
Cartography and GIS

Universitaetstr. 7, A-1010 Wien, AUSTRIA

Tel: (+43 1) 4277 48644
Fax: (+43 1) 4277 48649
E-mail: alexander.pucher@univie.ac.at

FTP: ftp://ftp.gis.univie.ac.at
WWW: http://www.gis.univie.ac.at/karto
--------------------------------------------------------
Virtual Map Forum: http://www.gis.univie.ac.at/vmf
--------------------------------------------------------
It's not that I'm afraid to die,
I just don't want to be there when it happens -- Woody Allen



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

Предыдущее
От: "cristi"
Дата:
Сообщение: select
Следующее
От: Manfred Koizar
Дата:
Сообщение: Re: Sum of two rows