Sum sets of records

Поиск
Список
Период
Сортировка
От Ezequias Rodrigues da Rocha
Тема Sum sets of records
Дата
Msg-id 55c095e90702120741w3908f730vbd23b6d9b4fa7cc3@mail.gmail.com
обсуждение исходный текст
Ответы Re: Sum sets of records  ("Bart Degryse" <Bart.Degryse@indicator.be>)
RE : Sum sets of records  (Sylvain Barrette <sylvain@remax-quebec.com>)
Список pgsql-sql
Hi list,<br /><br />I would like a little help from you to get the sum value of various subsets of my table.<br /><br
/>Mytable is like this<br /><br />id | type | value<br />1   C       10.00<br />2   C       15.00<br />3  W       
5.00<br/> 4  W        3.00<br /><br />Where C is credit and w is witdraw.<br /><br />How do I sum all records with C
andsubtract with all records with type W ?<br /><br />Is it possible ?<br /><span style="font-weight:
bold;">Ezequias</span><brclear="all" /><br /> 

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

Предыдущее
От: Richard Huxton
Дата:
Сообщение: Re: COPY FROM query.
Следующее
От: "Bart Degryse"
Дата:
Сообщение: Re: Sum sets of records