英文:
PostgreSQL autovacuum Statistic Level For Table Column
问题
我们可以通过检查pg_class的reloptions列来列出表的自定义选项。例如; 类似这篇帖子。
select relname, reloptions
from pg_class
where relname = 'a_table';
然而,我在官方文档和互联网上找不到关于在修改列后列出自定义统计设置的任何信息,就像这样:
ALTER TABLE name ALTER [ COLUMN ] column_name SET STATISTICS integer;
我们如何列出这些设置呢?
英文:
We can list tables' s custom options why checking pg_class' s reloptions columns. For example; like this post.
select relname, reloptions
from pg_class
where relname = 'a_table';
Yet, I couldn' t find anything in official documents and on the internet to list custom statistic settings for columns after altering them like this:
ALTER TABLE name ALTER [ COLUMN ] column_name SET STATISTICS integer;
How can we list those settings?
答案1
得分: 0
统计目标不是表的属性,而是列的属性。因此,您将在列的元数据表pg_attribute
中找到它。涉及的列是attstattarget
。其他每列设置可以在attoptions
中找到。
英文:
The statistics target is not a property of the table, but a property of the column. Therefore, you will find it in the metadata table of columns, which is pg_attribute
. The column in question is attstattarget
. Other per-column settings can be found in attoptions
.
通过集体智慧和协作来改善编程学习和解决问题的方式。致力于成为全球开发者共同参与的知识库,让每个人都能够通过互相帮助和分享经验来进步。
评论