Re: ERROR: ExecEvalAggref: no aggregates in this expressioncontext

Поиск
Список
Период
Сортировка
От Paul McGarry
Тема Re: ERROR: ExecEvalAggref: no aggregates in this expressioncontext
Дата
Msg-id 3963DA0C.B248C79D@opentec.com.au
обсуждение исходный текст
Ответ на ERROR: ExecEvalAggref: no aggregates in this expression context  (Paul McGarry <paulm@opentec.com.au>)
Ответы Re: ERROR: ExecEvalAggref: no aggregates in this expressioncontext  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-sql
Hi Tom,

Tom Lane wrote:
> > ERROR: ExecEvalAggref: no aggregates in this expression context
> > Does it mean that there aren't any aggregate in the expression
> > context when there should be.
> Yup.  ExecEvalAggref is supposed to fetch the result of a (previously
> computed) aggregate function.  It's unhappy because it's not finding
> anything to return.  This is a bug --- can we see a complete example
> that causes it?

The view that I am experiencing this error on is rather nasty, so
much so that I am going to solve the problem it was supposed to
solve in another way.

On another (possibly related) note, the same view seems to pose
problems when I do a 'SELECT count(*) from view_name'.

If I do a 'SELECT * from view_name' and get 8 rows of data, when Ido a 'SELECT count(*) from view_name' I get 8 rows of
the
 
number 1 returned. 

In any case I'll try and distill both of these down to a slightly 
less horrific testcase and send it in.

-- 
Paul McGarry            mailto:paulm@opentec.com.au 
Systems Integrator      http://www.opentec.com.au 
Opentec Pty Ltd         http://www.iebusiness.com.au
6 Lyon Park Road        Phone: (02) 9878 1744 
North Ryde NSW 2113     Fax:   (02) 9878 1755


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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: ERROR: ExecEvalAggref: no aggregates in this expression context
Следующее
От: Paul McGarry
Дата:
Сообщение: Re: ERROR: ExecEvalAggref: no aggregates in thisexpressioncontext