Search Postgresql Archives

Re: Is there a way too speed up Limit with high OFFSET ?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Le 12/08/2010 09:43, Georgi Ivanov a écrit :
> [...]
> I have query like this
> Select * from tabelname limit 10 OFFSET 10;
> 
> If i increase the OFFSET to 1000 for example, the query runs slower . The
> bigger is OFFSET the slower is the query.
> 
> This is standard pagination feature i use for my website.
> Actually the query is little bit more complex than this, but it is generally
> a
> select with a join.
> 
> So i wander if there is a way to speed up this kind of query ?
> 

You should better use cursors, than the OFFSET/LIMIT clause.


-- 
Guillaume
 http://www.postgresql.fr
 http://dalibo.com

-- 
Sent via pgsql-general mailing list (pgsql-general@xxxxxxxxxxxxxx)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux