Create functions pg_set_relation_stats, pg_clear_relation_stats.

These functions are used to tweak statistics on any relation, provided
that the user has MAINTAIN privilege on the relation, or is the database
owner.

Bump catalog version.

Author: Corey Huinker
Discussion: 
https://postgr.es/m/CADkLM=eergzn7ecdpwfcptjkok9sxzek5pot4d94evtzsvj...@mail.gmail.com

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/e839c8ecc9352b7754e74f19ace013c0c0d18613

Modified Files
--------------
doc/src/sgml/func.sgml                     |  94 +++++++++++++
src/backend/catalog/system_functions.sql   |  10 ++
src/backend/statistics/Makefile            |   4 +-
src/backend/statistics/meson.build         |   2 +
src/backend/statistics/relation_stats.c    | 210 +++++++++++++++++++++++++++++
src/backend/statistics/stat_utils.c        |  94 +++++++++++++
src/include/catalog/catversion.h           |   2 +-
src/include/catalog/pg_proc.dat            |  15 +++
src/include/statistics/stat_utils.h        |  29 ++++
src/test/regress/expected/stats_import.out | 143 ++++++++++++++++++++
src/test/regress/parallel_schedule         |   2 +-
src/test/regress/sql/stats_import.sql      |  98 ++++++++++++++
12 files changed, 700 insertions(+), 3 deletions(-)

Reply via email to