X-Original-To: pgsql-sql-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.2]) by svr1.postgresql.org (Postfix) with ESMTP id C969CD1B508 for ; Wed, 12 Nov 2003 10:57:44 +0000 (GMT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (neptune.hub.org [200.46.204.2]) (amavisd-new, port 10024) with ESMTP id 55222-09 for ; Wed, 12 Nov 2003 06:57:16 -0400 (AST) Received: from main.gmane.org (main.gmane.org [80.91.224.249]) by svr1.postgresql.org (Postfix) with ESMTP id 990B5D1B504 for ; Wed, 12 Nov 2003 06:57:13 -0400 (AST) Received: from list by main.gmane.org with local (Exim 3.35 #1 (Debian)) id 1AJsgP-0005ZN-00 for ; Wed, 12 Nov 2003 11:57:09 +0100 X-Injected-Via-Gmane: http://gmane.org/ To: pgsql-sql@postgresql.org Received: from sea.gmane.org ([80.91.224.252]) by main.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 1AJsgO-0005ZF-00 for ; Wed, 12 Nov 2003 11:57:08 +0100 Received: from news by sea.gmane.org with local (Exim 3.35 #1 (Debian)) id 1AJsgO-00050x-00 for ; Wed, 12 Nov 2003 11:57:08 +0100 From: Troels Arvin Subject: Re: Quota query with decent performance? Date: Wed, 12 Nov 2003 11:57:08 +0100 Lines: 12 Message-ID: References: Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit X-Complaints-To: usenet@sea.gmane.org User-Agent: Pan/0.14.2 (This is not a psychotic episode. It's a cleansing moment of clarity.) X-Virus-Scanned: by amavisd-new at postgresql.org X-Archive-Number: 200311/135 X-Sequence-Number: 15950 On Tue, 11 Nov 2003 18:49:31 -0500, Chester Kustarz wrote: > select * > from person > where age <= > (select age from person order by age limit 1 offset 2); Integrated into http://troels.arvin.dk/db/rdbms/#select-top-n -- Greetings from Troels Arvin, Copenhagen, Denmark