improve examples.
Mark Kirkwood
isdirty boolean);
regression=# SELECT c.relname, count(*) AS buffers
- FROM pg_class c, pg_buffercache b
- WHERE b.relfilenode = c.relfilenode
+ FROM pg_class c INNER JOIN pg_buffercache b
+ ON b.relfilenode = c.relfilenode INNER JOIN pg_database d
+ ON (b.reldatabase = d.oid AND d.datname = current_database())
GROUP BY c.relname
ORDER BY 2 DESC LIMIT 10;
relname | buffers
-- Adjust this setting to control where the objects get created.
+BEGIN;
SET search_path = public;
-- Register the function.
-- Don't want these to be available at public.
REVOKE ALL ON FUNCTION pg_buffercache_pages() FROM PUBLIC;
REVOKE ALL ON pg_buffercache FROM PUBLIC;
+
+COMMIT;