Re: [HACKERS] Should the following work...? - Mailing list pgsql-hackers

From Clark Evans
Subject Re: [HACKERS] Should the following work...?
Date
Msg-id 37011940.8C70AE72@manhattanproject.com
Whole thread Raw
In response to Should the following work...?  (The Hermit Hacker <scrappy@hub.org>)
List pgsql-hackers
The Hermit Hacker wrote:
> 
> select id
>   from clients
>  where id = ( select id
>                 from clients
>                where count(id) = 1 ) ;
> 

What are you trying to do, grab the id 
of the first row in the table?

If this is so, try:
select id from clients limit 1;

Otherwise, I can't figure out what
the above code is trying to accomplish.

Best,

Clark


pgsql-hackers by date:

Previous
From: The Hermit Hacker
Date:
Subject: RE: [HACKERS] Should the following work...?
Next
From: The Hermit Hacker
Date:
Subject: RE: [HACKERS] Should the following work...?