pg.ddx.io pgsql-performance@postgresql.org mailing list archive
help / color / mirror / Atom feedTablespaces and query planning
3+ messages / 2 participants
[nested] [flat]
* Tablespaces and query planning
@ 2012-06-08 08:15 Albe Laurenz <laurenz.albe@wien.gv.at>
0 siblings, 1 reply; 3+ messages in thread
From: Albe Laurenz @ 2012-06-08 08:15 UTC (permalink / raw)
To: pgsql-performance
Could somebody confirm or refute the following statements, please?
- The statistics gathered by ANALYZE are independent of the tablespace
containing the table.
- The tablespace containing the table has no influence on query planning
unless seq_page_cost or random_page_cost has been set on the
tablespace.
- VACUUM ANALYZE does the same as VACUUM followed by ANALYZE.
Yours,
Laurenz Albe
^ permalink raw reply [nested|flat] 3+ messages in thread
* Re: Tablespaces and query planning
@ 2012-06-08 10:36 Cédric Villemain <cedric@2ndquadrant.com>
parent: Albe Laurenz <laurenz.albe@wien.gv.at>
0 siblings, 1 reply; 3+ messages in thread
From: Cédric Villemain @ 2012-06-08 10:36 UTC (permalink / raw)
To: pgsql-performance; +Cc: Albe Laurenz <laurenz.albe@wien.gv.at>
> - The statistics gathered by ANALYZE are independent of the tablespace
> containing the table.
yes.
> - The tablespace containing the table has no influence on query planning
> unless seq_page_cost or random_page_cost has been set on the
> tablespace.
yes.
> - VACUUM ANALYZE does the same as VACUUM followed by ANALYZE.
no.
it is fine grained, but in the diffs there is:
VACUUM and ANALYSE do not update pg_class the same way for the
reltuples/relpages: for ex VACUUM is accurate for index, and ANALYZE is fuzzy
so if you issue a vacuum you have exact values, if you then run ANALYZE you
may change them to be less precise.
--
Cédric Villemain +33 (0)6 20 30 22 52
http://2ndQuadrant.fr/
PostgreSQL: Support 24x7 - Développement, Expertise et Formation
Attachments:
signature.asc (application/pgp-signature, 489B) download
^ permalink raw reply [nested|flat] 3+ messages in thread
* Re: Tablespaces and query planning
@ 2012-06-11 07:01 Albe Laurenz <laurenz.albe@wien.gv.at>
parent: Cédric Villemain <cedric@2ndquadrant.com>
0 siblings, 0 replies; 3+ messages in thread
From: Albe Laurenz @ 2012-06-11 07:01 UTC (permalink / raw)
To: cedric@2ndquadrant.com; pgsql-performance
Cédric Villemain wrote:
> > - The statistics gathered by ANALYZE are independent of the tablespace
> > containing the table.
>
> yes.
>
> > - The tablespace containing the table has no influence on query planning
> > unless seq_page_cost or random_page_cost has been set on the
> > tablespace.
>
> yes.
>
> > - VACUUM ANALYZE does the same as VACUUM followed by ANALYZE.
>
> no.
> it is fine grained, but in the diffs there is:
>
> VACUUM and ANALYSE do not update pg_class the same way for the
> reltuples/relpages: for ex VACUUM is accurate for index, and ANALYZE is fuzzy
> so if you issue a vacuum you have exact values, if you then run ANALYZE you
> may change them to be less precise.
Thanks for the confirmationsand the clarification. I hadn't thought of the
statistical entries in pg_class.
Yours,
Laurenz Albe
^ permalink raw reply [nested|flat] 3+ messages in thread
end of thread, other threads:[~2012-06-11 07:01 UTC | newest]
Thread overview: 3+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2012-06-08 08:15 Tablespaces and query planning Albe Laurenz <laurenz.albe@wien.gv.at>
2012-06-08 10:36 ` Cédric Villemain <cedric@2ndquadrant.com>
2012-06-11 07:01 ` Albe Laurenz <laurenz.albe@wien.gv.at>
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox