postgresql/src/include/catalog
Tom Lane e6858e6657 Measure the number of all-visible pages for use in index-only scan costing.
Add a column pg_class.relallvisible to remember the number of pages that
were all-visible according to the visibility map as of the last VACUUM
(or ANALYZE, or some other operations that update pg_class.relpages).
Use relallvisible/relpages, instead of an arbitrary constant, to estimate
how many heap page fetches can be avoided during an index-only scan.

This is pretty primitive and will no doubt see refinements once we've
acquired more field experience with the index-only scan mechanism, but
it's way better than using a constant.

Note: I had to adjust an underspecified query in the window.sql regression
test, because it was changing answers when the plan changed to use an
index-only scan.  Some of the adjacent tests perhaps should be adjusted
as well, but I didn't do that here.
2011-10-14 17:23:46 -04:00
..
.gitignore
catalog.h Fix bug introduced by pgrminclude where the tablespace version name was 2011-09-07 12:41:16 -04:00
catversion.h Measure the number of all-visible pages for use in index-only scan costing. 2011-10-14 17:23:46 -04:00
dependency.h Remove unnecessary #include references, per pgrminclude script. 2011-09-01 10:04:27 -04:00
duplicate_oids
genbki.h
heap.h Avoid index rebuild for no-rewrite ALTER TABLE .. ALTER TYPE. 2011-07-18 11:04:43 -04:00
index.h Avoid index rebuild for no-rewrite ALTER TABLE .. ALTER TYPE. 2011-07-18 11:04:43 -04:00
indexing.h Support SECURITY LABEL on databases, tablespaces, and roles. 2011-07-20 13:18:24 -04:00
namespace.h Redesign the plancache mechanism for more flexibility and efficiency. 2011-09-16 00:43:52 -04:00
objectaccess.h pgindent run before PG 9.1 beta 1. 2011-04-10 11:42:00 -04:00
objectaddress.h Remove rel.h from objectaddress.h; only relcache.h is necessary. 2011-06-28 17:08:29 -04:00
pg_aggregate.h
pg_am.h Support index-only scans using the visibility map to avoid heap fetches. 2011-10-07 20:14:13 -04:00
pg_amop.h
pg_amproc.h
pg_attrdef.h
pg_attribute.h Allow per-column foreign data wrapper options. 2011-08-05 13:24:03 -04:00
pg_auth_members.h
pg_authid.h
pg_cast.h
pg_class.h Measure the number of all-visible pages for use in index-only scan costing. 2011-10-14 17:23:46 -04:00
pg_collation_fn.h
pg_collation.h
pg_constraint.h
pg_control.h Oops, we're working on version 9.2 already, not 9.1. Update the 2011-08-10 09:28:26 +03:00
pg_conversion_fn.h Stamp copyrights for year 2011. 2011-01-01 13:18:15 -05:00
pg_conversion.h
pg_database.h
pg_db_role_setting.h Remove unnecessary #include references, per pgrminclude script. 2011-09-01 10:04:27 -04:00
pg_default_acl.h
pg_depend.h
pg_description.h
pg_enum.h
pg_extension.h
pg_foreign_data_wrapper.h
pg_foreign_server.h Stamp copyrights for year 2011. 2011-01-01 13:18:15 -05:00
pg_foreign_table.h
pg_index.h
pg_inherits_fn.h
pg_inherits.h
pg_language.h
pg_largeobject_metadata.h
pg_largeobject.h
pg_namespace.h
pg_opclass.h
pg_operator.h
pg_opfamily.h
pg_pltemplate.h
pg_proc_fn.h
pg_proc.h Create a "fast path" for acquiring weak relation locks. 2011-07-18 00:49:28 -04:00
pg_rewrite.h Stamp copyrights for year 2011. 2011-01-01 13:18:15 -05:00
pg_seclabel.h
pg_shdepend.h
pg_shdescription.h
pg_shseclabel.h Support SECURITY LABEL on databases, tablespaces, and roles. 2011-07-20 13:18:24 -04:00
pg_statistic.h
pg_tablespace.h
pg_trigger.h
pg_ts_config_map.h Stamp copyrights for year 2011. 2011-01-01 13:18:15 -05:00
pg_ts_config.h
pg_ts_dict.h
pg_ts_parser.h
pg_ts_template.h Stamp copyrights for year 2011. 2011-01-01 13:18:15 -05:00
pg_type_fn.h
pg_type.h
pg_user_mapping.h
storage.h Clean up the #include mess a little. 2011-09-04 01:13:16 -04:00
toasting.h
unused_oids