Re: How to get single raws for sums in a summary table?

Поиск
Список
Период
Сортировка
От Ennio-Sr
Тема Re: How to get single raws for sums in a summary table?
Дата
Msg-id 20061122192215.GA6425@deby.ei.hnet
обсуждение исходный текст
Ответ на Re: How to get single raws for sums in a summary table?  (Richard Broersma Jr <rabroersma@yahoo.com>)
Ответы Re: How to get single raws for sums in a summary table?  (Richard Broersma Jr <rabroersma@yahoo.com>)
Список pgsql-novice
* Richard Broersma Jr <rabroersma@yahoo.com> [221106, 06:53]:
> Oops I tested this and didn't get what you wanted. try this instead.
>
> >
> > This is untested. Also I am not sure that this is what you want, but I do not know how you
> > arrive
> > at the values in your summary table.
> >
> > select
> >         distinct on (titolo)
>                        ^^^^^^
> ...
>
> Regards,
> Richard Broersma Jr.

Hi Richard (and others),

I was cheering too early in my previous answer ;)
The query is only apparently  giving a sum: in effect the value in each
raw is just one of the values of raws having the same 'titolo'.

What I had in mind was the possibility to achieve the same result I used
to get (quite a few years back) in DBIII, when printing data and setting
subtotals for same items. But this is history ......

Anyway, thanks again for attention and help.
Regards,
    Ennio.

--
[Perche' usare Win$ozz (dico io) se ..."anche uno sciocco sa farlo.   \\?//
 Fa' qualche cosa di cui non sei capace!"  (diceva Henry Miller) ]    (°|°)
[Why use Win$ozz (I say) if ... "even a fool can do that.              )=(
 Do something you aren't good at!" (as Henry Miller used to say) ]

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

Предыдущее
От: Ennio-Sr
Дата:
Сообщение: Re: How to get single raws for sums in a summary table?
Следующее
От: Richard Broersma Jr
Дата:
Сообщение: Re: How to get single raws for sums in a summary table?