Re: Problems with PostgreSQL 7.1.2

From: "Oliver Elphick" <olly(at)lfix(dot)co(dot)uk>
To: Fabio Sobral <sobral(at)lncc(dot)br>
Cc: pgadmin <pgsql-admin(at)postgresql(dot)org>
Subject: Re: Problems with PostgreSQL 7.1.2
Date: 2001-08-03 12:39:40
Message-ID: 200108031239.f73CdeGn006789@linda.lfix.co.uk
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-admin

Fabio Sobral wrote:
>Dear Sirs,
>
> In old versions of PostgreSQL, we could see the database names in the
>pgsql/data/base directory, perhaps in this version, we can´t see the
>database names, we see numbers that represents the databases. I would
>like to know how can I do to appear the databases names instead of
>numbers.

To find the table name to file mapping in a database:

SELECT relname, relfilenode
FROM pg_class
ORDER BY relname;

relfilenode seems to be the same as the table's oid, but there must be
circumstances where that is not the case.

To find the mapping of databases to the numbers under ${PGDATA}/base:

SELECT datname, oid
FROM pg_database
ORDER BY datname;

--
Oliver Elphick Oliver(dot)Elphick(at)lfix(dot)co(dot)uk
Isle of Wight http://www.lfix.co.uk/oliver
PGP: 1024R/32B8FAA1: 97 EA 1D 47 72 3F 28 47 6B 7E 39 CC 56 E4 C1 47
GPG: 1024D/3E1D0C1C: CA12 09E0 E8D5 8870 5839 932A 614D 4C34 3E1D 0C1C
========================================
"Love is patient, love is kind. It does not envy, it
does not boast, it is not proud. It is not rude, it is
not self seeking, it is not easily angered, it keeps
no record of wrongs. Love does not delight in evil but
rejoices with the truth. It always protects, always
trusts, always hopes, always perseveres."
I Corinthians 13:4-7

Browse pgsql-admin by date

  From Date Subject
Next Message pmiranda 2001-08-03 15:29:37 Can't I do that?
Previous Message Jason 2001-08-03 11:50:01 A replication like process