invalid 'having' clause - Mailing list pgsql-sql

From Iain
Subject invalid 'having' clause
Date
Msg-id 001601c4d815$d8f03430$7201a8c0@mst1x5r347kymb
Whole thread Raw
Responses Re: invalid 'having' clause
List pgsql-sql
Hi,

Just a quick question out of curiosity, I was just wondering if this is 
supposed to be valid sql:

select count(*) as cnt
from sometable
group by somecolumn
having cnt > 1

This isn't valid in pg (7.4.6), but this is:

select count(*)
from sometable
group by somecolumn
having count(*) > 1

Does anyone have any idea?

I can't remember what other databases do, and I'm not so familiar with the 
standards, but I just thought I'd mention it anyway.

regards
Iain 



pgsql-sql by date:

Previous
From: Michael Fuhr
Date:
Subject: Re: Found Large Files.. what objects are they?
Next
From: Michael Fuhr
Date:
Subject: Re: grouping a many to many relation set