On 29/09/2020 11:49, Hamid Akhtar wrote:
So, not actually random replacement here, rather a change with baserel->allvisfrac taken into consideration (as given below):
----
index_random_page_cost = Min(spc_seq_page_cost + spc_random_page_cost * (1.0 - baserel->allvisfrac), spc_random_page_cost);
----

Does this make sense?

No. genericcostestimate() is only concerned with accesses to the index, not the the heap accesses that are needed with Index Scans. 'allvisfrac' should not affect the number of *index* pages fetched in any way.

- Heikki


Reply via email to