Thread: Re: [SQL] OFFSET impact on Performance???

Re: [SQL] OFFSET impact on Performance???

From
"Merlin Moncure"
Date:
> Actually, you can if you assume you can "temporarily materialize" that
> view.
>
> Then, you use a join on my_query to pull the bits you want:
>
>   select [big table.details] from [big table],
>   [select * from my_query order by [something] offset 280 limit 20]
>   where [join criteria between my_query and big table]
>   order by [something];
>

I think that's a pretty reasonable compromise between a true
materialized solution and brute force limit/offset.  Still, the
performance of a snapshot materialized view indexed around your query
simply can't be beat, although you have to pay a hefty price in
complexity, maintenance, and coherency.

Merlin