Does postgresql support storage clause when creating tables

Поиск
Список
Период
Сортировка
От Guang Mei
Тема Does postgresql support storage clause when creating tables
Дата
Msg-id F156gUFDKPGzGqiuLeH00000df5@hotmail.com
обсуждение исходный текст
Список pgsql-general
Hi:

A postgresql newbie question. First a little background here, I just started
working on postgresql yesterday. We have an oracle database running and we
are planning to support it on postgresql platform too. I installed
postgres703 on our RedHat linux 7.0 box and was able to create a "testdb"
and use "psql" to "play" a bit. Now I would like to create the same tables
that we have in the oracle db. For example, in oracle I would issue:

CREATE TABLE HpxNewBrand(
    BrandID       NUMBER(9, 0)    NOT NULL,
    VendorName    VARCHAR2(40),
    ReBrand       VARCHAR2(44),
    CONSTRAINT PKHpxNewBrand PRIMARY KEY (BrandID)
    USING INDEX TABLESPACE INDX
    STORAGE(INITIAL 50K
        NEXT 25K
        MINEXTENTS 1
        MAXEXTENTS UNLIMITED
        PCTINCREASE 0
        )
)
TABLESPACE DATA
STORAGE(INITIAL 500K
        NEXT 500K
        MINEXTENTS 1
        MAXEXTENTS UNLIMITED
        PCTINCREASE 0
        );

because in oracle I can separate table and index into different
"tablespace". And I can also specify storage clause for disk space
allocation.

How do I do this in postgresql in the following command?

CREATE TABLE HpxNewBrand(
    BrandID       NUMBER(9, 0)    NOT NULL,
    VendorName    VARCHAR2(40),
    ReBrand       VARCHAR2(44),
    CONSTRAINT PKHpxNewBrand PRIMARY KEY (BrandID);


I looked at User's Guide, it seems that postgres does not support "storage
clause". How do I allocate a "big block" to store my data?

I have another table that have 0.25 million records and they don't change
often. I want to allocate one big "extent" so that there will not be
"de-fragmentation" on the disk. How could I do that?

TIA

Guang

_________________________________________________________________
Get your FREE download of MSN Explorer at http://explorer.msn.com


В списке pgsql-general по дате отправления:

Предыдущее
От: Roland Roberts
Дата:
Сообщение: Re: extra spaces
Следующее
От:
Дата:
Сообщение: How to make user-defined data types?