count(imdb_id) problem

From: William Wallace <vplia(at)otenet(dot)gr>
To: pgsql-novice(at)postgresql(dot)org
Subject: count(imdb_id) problem
Date: 2006-04-10 04:46:44
Message-ID: 4439E334.4030903@otenet.gr
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-novice

Hello community!

When I type a query in postgresql, like

select id,imdb_id,count(imdb_id) from "Movies" where id<10 group by imdb_id;

it says: column "Movies.id" must appear in the GROUP BY clause or be
used in an aggregate function
Where is the error?
What is the right spelling of this query?

Browse pgsql-novice by date

  From Date Subject
Next Message Ntina Papadopoulou 2006-04-10 05:28:12 select id,count(imdb_id) problem
Previous Message Alan Hodgson 2006-04-09 20:55:46 Re: replication