Re: OK, OK, Hiroshi's right: use a seperately-generated filename - Mailing list pgsql-hackers

From Peter Eisentraut
Subject Re: OK, OK, Hiroshi's right: use a seperately-generated filename
Date
Msg-id Pine.LNX.4.21.0006170403000.17284-100000@localhost.localdomain
Whole thread Raw
In response to OK, OK, Hiroshi's right: use a seperately-generated filename  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: OK, OK, Hiroshi's right: use a seperately-generated filename  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-hackers
Tom Lane writes:

>     tablespace/%d/12345_relname

Throwing table spaces and relation names into one pot doesn't excite me
very much. For example, before long people will want to

* Query what tables are in what space (without using string operations)
Consider for example creating a new table and choosing where to put it.

* Rename table spaces

* Assign attributes of some sort to table spaces (permissions, etc.)

* Use table space names with more than 15 characters. :)

Somehow table spaces need to be catalogued. You could still make the
physical file name 'tablespaceoid/rest' without actually having to look up
anything, although that depends on your symlink idea which is still under
discussion.

Then, why are all nth segments of tables in one directory in that
proposal?

Also, you said before that an old relname (after rename) is worse than
none at all. I couldn't agree more.

Why not use OID.[SEGMENT.]VERSION for the physical relname (different
order possible)? That way you at least have some guaranteed correspondence
between files and tables. Version could probably be an INT2, so you save
some space.


-- 
Peter Eisentraut                  Sernanders väg 10:115
peter_e@gmx.net                   75262 Uppsala
http://yi.org/peter-e/            Sweden



pgsql-hackers by date:

Previous
From: Peter Eisentraut
Date:
Subject: Install modes
Next
From: Peter Eisentraut
Date:
Subject: Re: create user and transactions