Aggregates don't work on views?

Поиск
Список
Период
Сортировка
Искать
От
Jeremy Buchmann
Тема
Aggregates don't work on views?
Дата
в 18:54:18
Msg-id
B73430A4.2ED5%jeremy@wellsgaming.com
Список
Дерево обсуждения
Aggregates don't work on views? Jeremy Buchmann <jeremy@wellsgaming.com>
Re: Aggregates don't work on views? Tom Lane <tgl@sss.pgh.pa.us>
Hello all,

I am trying to select the sum of a column in a view, but it doesn't give me
any data.  Check this out (h_2535c_1_this is the view):

rb=> select avg_rate from h_2535c_1_this;
avg_rate
--------
    40.5
      51
      38
      37
(4 rows)

rb=> select sum(avg_rate) from h_2535c_1_this;
sum
---
   
   
   
   
(4 rows)


What's happening here?  I'm using pg 6.5.3 (yes, I know it's time to
upgrade, I will when it's feasible to take down our production server) on
Linux 2.2.19 (SuSE).

Thanks,

-- Jeremy


В списке pgsql-admin по дате отправления
От: Tom Lane
Дата:
От: Tom Lane
Дата:
FAQ