> In both cases, he recently dead tuples must be copied to the table or index, > but > they should not be counted towards reltuples. So, I think we need to fix this > in > heapam_relation_copy_for_cluster by probably subtracting > tups_recently_dead from num_tuples ( which is the value set in > pg_class.reltuples ) > after we process all the tuples, which looks like the best fix to me.
something like the attached. -- Sami Imseih Amazon Web Services (AWS)
v1-0001-Correct-reltuples-count-after-a-VACUUM-CLUSTER-op.patch
Description: Binary data