Skip site navigation (1) Skip section navigation (2)

Group By problem

From: kmi(at)st(dot)uz
To: pgsql-novice(at)postgresql(dot)org
Subject: Group By problem
Date: 2006-09-21 07:06:58
Message-ID: 57011.217.29.116.250.1158822418.squirrel@mail.st.uz (view raw or flat)
Thread:
Lists: pgsql-novice
I have such problem:
need to get full record from a table that fits my conditions

SELECT * FROM groups WHERE grouptype=7 GROUP BY groupid HAVING
max(datecreate)>'2006-09-01'

Postgres tells i should group all fields but this fields have only same
groupid field value, and i need get full record. This must be a common
problem i think. How can i solve this?


Responses

pgsql-novice by date

Next:From: snake84@inwind.itDate: 2006-09-21 11:23:43
Subject: Assertion
Previous:From: Michael FuhrDate: 2006-09-21 03:08:07
Subject: Re: Server->Client notification (without polling)?

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group