Re: Datafiles for Databases

From: Christopher Browne <cbbrowne(at)acm(dot)org>
To: pgsql-sql(at)postgresql(dot)org
Subject: Re: Datafiles for Databases
Date: 2003-09-19 10:48:29
Message-ID: m34qz9oxz6.fsf@wolfe.cbbrowne.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql

In the last exciting episode, sgnerd(at)yahoo(dot)com(dot)sg ("Kumar") wrote:
> I was looking for a structure like oracle or ms Sql server in Postgres. What I have expected is individual
> datafiles for individual databases. But i cant fine such items in the /usr/local/pgsql/data directory.
>
> Will the postgres create individual data file for databases?

No. Just as with Oracle, PostgreSQL creates multiple files for each
database.

> How to get the datafile path of a database?

select oid, datname from pg_database;

The path for database 'datname' will be:
$PGDATA/base/oid/
--
"aa454","@","freenet.carleton.ca"
http://cbbrowne.com/info/x.html
People can be set wondering by loading obscure personal patchable
systems, and sending bug reports. Who would not stop and wonder upon
seeing "Experimental TD80-TAPE 1.17, MegaDeath 2.5..."? The same for
provocatively-named functions and variables in stack traces.
-- from the Symbolics Guidelines for Sending Mail

In response to

Responses

Browse pgsql-sql by date

  From Date Subject
Next Message Christopher Browne 2003-09-19 10:49:36 Re: virus warning
Previous Message Christopher Browne 2003-09-19 10:42:54 Re: Automated Backup