Re: best paging strategies for large datasets?

Поиск
Список
Период
Сортировка
От Justin Graf
Тема Re: best paging strategies for large datasets?
Дата
Msg-id 4BEC0564.7020403@magwerks.com
обсуждение исходный текст
Ответ на Re: best paging strategies for large datasets?  (Louis-David Mitterrand <vindex+lists-pgsql-sql@apartia.org>)
Список pgsql-sql
On 5/13/2010 3:43 AM, Louis-David Mitterrand wrote:
**snip***
>
>> What do you mean by quite slow??
>>      
> Like several seconds. I have to cache the results.
>    

Well then i suggest posting the queries to Performance or here and let 
us take a look them
don't forget to include the explain/analyze, and number of records in 
each table.
>> On a 30K record table count() and query speed should not be a problem..
>>      
> This query is a large multi-join of times series data, not a single
> table. And it's not (prematurely :) optimized.
>
> I'm planning a materialized view for it.
>    

here read this
http://www.pgcon.org/2008/schedule/events/69.en.html

The question that begs to be asked how big are the tables the query is 
accessing??

if its not hundreds of thousands to millions of records or on a stone 
age Server , my guess is  the  query can be improved.


> **snip**
>> RecordCount/Limit = Number of pages
>> CurrentPage = (offset%RecordCount)/Limit
>>      
> These simple formulas we bill handy.
>    

don't forget to use floor on these in what ever language your 
programming in




All legitimate Magwerks Corporation quotations are sent in a .PDF file attachment with a unique ID number generated by
ourproprietary quotation system. Quotations received via any other form of communication will not be honored.
 

CONFIDENTIALITY NOTICE: This e-mail, including attachments, may contain legally privileged, confidential or other
informationproprietary to Magwerks Corporation and is intended solely for the use of the individual to whom it
addresses.If the reader of this e-mail is not the intended recipient or authorized agent, the reader is hereby notified
thatany unauthorized viewing, dissemination, distribution or copying of this e-mail is strictly prohibited. If you have
receivedthis e-mail in error, please notify the sender by replying to this message and destroy all occurrences of this
e-mailimmediately.
 
Thank you.



В списке pgsql-sql по дате отправления:

Предыдущее
От: Justin Graf
Дата:
Сообщение: Re: best paging strategies for large datasets?
Следующее
От: Rob Sargent
Дата:
Сообщение: Re: Invalid message format Exception