Greenplum Server/Kernel about analyzedb
search cancel

Greenplum Server/Kernel about analyzedb

book

Article ID: 423262

calendar_today

Updated On:

Products

VMware Tanzu Greenplum

Issue/Introduction

I would expect if analyze is run manually on an AO table or an AO partition, the following analyzedb option would update a file in order to prevent analyzedb to take into account this table/partition:

--gen_profile_only
Update the analyzedb snapshot of table statistics information without performing any ANALYZE operations. If other options specify tables or a schema, the utility updates the snapshot information only for the specified tables.

Specify this option if the ANALYZE command was run on database tables and you want to update the analyzedb snapshot for the tables.

From testing the analyzedb option --gen_profile_only doesn't differentiate the tables/partitions that were really analyzed.

Resolution

The --gen_profile_only option updates the state files for an AO table as if it were analyzed, without actually performing the analyze. It doesn't do any differentiation between whether it was actually analyzed.

In GPDB 7.5 with gp_analyze_only_modified_relations, an optimization to the ANALYZE command that skips statistical computation if the table hasn't been modified since the last analysis. This effectively brings some analyzedb functionality into the server.

The new analyze improvements in 7.x should be much more helpful.