How to find the number of cached pages for a relation? - Mailing list pgsql-hackers

From Amin
Subject How to find the number of cached pages for a relation?
Date
Msg-id CAF-KA8_axSMpQW1scOTnAQx8NFHgmJc6L87QzAo3JezLiBU1HQ@mail.gmail.com
Whole thread Raw
Responses Re: How to find the number of cached pages for a relation?
List pgsql-hackers
Hi,

Before scanning a relation, in the planner stage, I want to make a call to retrieve information about how many pages will be a hit for a specific relation. The module pg_buffercache seems to be doing a similar thing. Also, pg_statio_all_tables seems to be having that information, but it is updated after execution. However, I want the information before execution. Also not sure how pg_statio_all_tables is created and how I can access it in the code.

Thank you!

pgsql-hackers by date:

Previous
From: Andrew Dunstan
Date:
Subject: Re: Fixes required for cross version update testing
Next
From: "David G. Johnston"
Date:
Subject: Re: pgsql: Add new GUC createrole_self_grant.