Re: Which file belongs to which database? - Mailing list pgsql-general

From Tom Lane
Subject Re: Which file belongs to which database?
Date
Msg-id 7999.1059140167@sss.pgh.pa.us
Whole thread Raw
In response to Re: Which file belongs to which database?  (Thomas Kellerer <spam_eater@gmx.net>)
List pgsql-general
Thomas Kellerer <spam_eater@gmx.net> writes:
> Shridhar Daithankar schrieb:
>> You can just find the oid of the object from catalog and search for that
>> file. That's the principle.

> That easy ? :-)

Actually you must look at pg_class.relfilenode; this is initially the
same as oid, but there are operations (such as cluster and reindex) that
assign new relfilenode values because they replace the underlying file.

At the database level, pg_database.oid is correct.

            regards, tom lane

pgsql-general by date:

Previous
From: "Reuben D. Budiardja"
Date:
Subject: Re: How to encrypt data in Postgresql
Next
From: "Reuben D. Budiardja"
Date:
Subject: Re: Can I turn the case sensitive off