Re: Difference between Access97 and PostgreSQL

Поиск
Список
Период
Сортировка
От Christopher Kings-Lynne
Тема Re: Difference between Access97 and PostgreSQL
Дата
Msg-id GNELIHDDFBOCMGBFGEFOKEDPCBAA.chriskl@familyhealth.com.au
обсуждение исходный текст
Ответ на Re: Difference between Access97 and PostgreSQL  (Roberto Mello <rmello@cc.usu.edu>)
Список pgsql-sql
> On Wed, Jan 30, 2002 at 11:54:56PM +0000, Yan Bai wrote:
> > 
> > --------------------------------------------------
> > SELECT temp.rating, temp.avgage
> > FROM (SELECT s.rating, AVG(s.age) as avgage
> >      FROM sailors s GROUP BY s.rating) as temp
> 
> Have you tried this query without the subselect? It looks like it should
> work.

What about this?

SELECT temp.rating, temp.avgage
FROM (SELECT s.rating, AVG(s.age) as avgage    FROM sailors s GROUP BY s.rating, s.age) as temp

Chris



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

Предыдущее
От: "Josh Berkus"
Дата:
Сообщение: Re: How to merge several attributes and Delete an
Следующее
От: "Henshall, Stuart - WCP"
Дата:
Сообщение: Re: Difference between Access97 and PostgreSQL