pg.ddx.io  pgsql-committers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
pgsql: Create functions pg_set_relation_stats, pg_clear_relation_stats.
3+ messages / 3 participants
[nested] [flat]

Commits from this thread:
  2024-10-16 b360d1762b  Fix #include order from e839c8ecc9.
* pgsql: Create functions pg_set_relation_stats, pg_clear_relation_stats.
@ 2024-10-11 23:57  Jeff Davis <jdavis@postgresql.org>
  0 siblings, 1 reply; 3+ messages in thread

From: Jeff Davis @ 2024-10-11 23:57 UTC (permalink / raw)
  To: pgsql-committers@lists.postgresql.org

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=eErgzn7ECDpwFcptJKOk9SxZEk5Pot4d94eVTZsvj3gw@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(-)



^ permalink  raw  reply  [nested|flat] 3+ messages in thread

* Re: pgsql: Create functions pg_set_relation_stats, pg_clear_relation_stats.
@ 2024-10-14 23:00  Alexander Korotkov <aekorotkov@gmail.com>
  parent: Jeff Davis <jdavis@postgresql.org>
  0 siblings, 1 reply; 3+ messages in thread

From: Alexander Korotkov @ 2024-10-14 23:00 UTC (permalink / raw)
  To: Jeff Davis <jdavis@postgresql.org>; +Cc: pgsql-committers@lists.postgresql.org

On Sun, Oct 13, 2024 at 6:21 PM Jeff Davis <jdavis@postgresql.org> wrote:
> 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.

+#include "utils/array.h"
+#include "utils/builtins.h"
+#include "utils/acl.h"
+#include "utils/rel.h"

Please, check the alphabetical order of includes in stat_utils.c.

------
Regards,
Alexander Korotkov
Supabase





^ permalink  raw  reply  [nested|flat] 3+ messages in thread

* Re: pgsql: Create functions pg_set_relation_stats, pg_clear_relation_stats.
@ 2024-10-16 19:14  Jeff Davis <pgsql@j-davis.com>
  parent: Alexander Korotkov <aekorotkov@gmail.com>
  0 siblings, 0 replies; 3+ messages in thread

From: Jeff Davis @ 2024-10-16 19:14 UTC (permalink / raw)
  To: Alexander Korotkov <aekorotkov@gmail.com>; Jeff Davis <jdavis@postgresql.org>; +Cc: pgsql-committers@lists.postgresql.org

On Tue, 2024-10-15 at 02:00 +0300, Alexander Korotkov wrote:
> Please, check the alphabetical order of includes in stat_utils.c.

Thank you, fixed. Did you use a tool or just happen to notice?

Regards,
	Jeff Davis






^ permalink  raw  reply  [nested|flat] 3+ messages in thread


end of thread, other threads:[~2024-10-16 19:14 UTC | newest]

Thread overview: 3+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2024-10-11 23:57 pgsql: Create functions pg_set_relation_stats, pg_clear_relation_stats. Jeff Davis <jdavis@postgresql.org>
2024-10-14 23:00 ` Alexander Korotkov <aekorotkov@gmail.com>
2024-10-16 19:14   ` Jeff Davis <pgsql@j-davis.com>

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