Re: [HACKERS] Efficiency of LIMIT ?

From: les(at)MCS(dot)COM (Leslie Mikesell)
To: pgsql-hackers(at)postgreSQL(dot)org
Subject: Re: [HACKERS] Efficiency of LIMIT ?
Date: 1999-04-27 01:53:23
Message-ID: 7g35aj$1trk$1@Venus.mcs.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

In article <199904251941(dot)PAA00652(at)candle(dot)pha(dot)pa(dot)us>,
Bruce Momjian <maillist(at)candle(dot)pha(dot)pa(dot)us> wrote:
>> > Is the LIMIT feature very efficient? I want to start using it for quite
>> > a few things, but I'm wondering, what happens when I have a zillion
>> > records and I want the first 10, is that going to be an efficient thing
>> > to do?
>>
>> I am curious about this myself. As far as I can tell, it doesn't
>> give anything that cursors don't provide, but introduces more "features"
>> into the parser. Do we need this?
>
>This is pretty correct, though it stops the executor from completing all
>the result queries, while cursors don't. The complete the entire query
>and store the result for later fetches.. We support it because MySQL
>users and others asked for it.

It is a nice touch for web interfaces that are going to display
so many records for a request and not maintain any state between
requests.

Les Mikesell
les(at)mcs(dot)com

Browse pgsql-hackers by date

  From Date Subject
Next Message The Hermit Hacker 1999-04-27 02:42:42 Re: [HACKERS] Re: CORBA again. (was: light dawns: serious bug in FE/BE protocol handling)
Previous Message Tatsuo Ishii 1999-04-27 01:32:36 unknown symbol 'lo_unlink'