The Hermit Hacker wrote:
>
> select id
> from clients
> where id = ( select id
> from clients
> where count(id) = 1 ) ;
>
Hmm. If you are trying to identify
duplicate id's then try :
select distinct id from client x
where 1 <
( select count(id)
from client y
where y.id = x.id );
Ideally, this would be done as:
select a from
( select a, count(a) cnt
from test
group by a ) where cnt < 2;
However, PostgreSQL dosn't support
dynamic views. This, btw, is a
very useful feature.
Hope this helps,
Clark