Search Postgresql Archives

Re: Read-only tables to avoid row visibility check

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

 



On Mon, Feb 22, 2016 at 2:35 PM, Seamus Abshere <seamus@xxxxxxxxxxx> wrote:
> hi,
>
> https://wiki.postgresql.org/wiki/ReadOnlyTables mentions the possibility
> of `ALTER TABLE table SET READ ONLY`.
>
> Would this mean that row visibility checks could be skipped and thus
> index-only scans much more common?

Personally I don't see how that buys you very much.  Right now you can
VACUUM the table which will update the visibility map, allowing index
only scans to be chosen.  Visibility checks are also already optimized
away by the database over time via hint bits.

I think the optimization you are looking for is to have the database
exploit the fact that when the table is created and/or loaded in a
single transaction, it marks everything visible and valid by default
and then wipes it all away should the insert fail.

merlin


-- 
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