Create a space inside a user's tablespace [message #646] |
Mon, 25 February 2002 13:57 |
Kevin Gary
Messages: 1 Registered: February 2002
|
Junior Member |
|
|
Is there any way to partition the tables inside a
user's tablespace and name that partition? By partition here I mean simply a subset of the tables, views, etc. in the student's overall tablespace. I looked at the create schema command, but I don't think that does the trick if I understand it right.
Thanks, Kevin
|
|
|
Re: Create a space inside a user's tablespace [message #649 is a reply to message #646] |
Mon, 25 February 2002 16:41 |
seng
Messages: 191 Registered: February 2002
|
Senior Member |
|
|
Yes, you can partition table on different tablespace with
CREATE SCHEMA <schema name> CREATE TABLE <clause>
or
CREATE TABLE <clause>.
For information, certain data is suitable to partition
E.g Date, to partition on month,year and so on. Below is sample of table partition.
CREATE TABLE
( field1 typefield1,
field2 typefield2,
field3 date)
STORAGE <storage clause>
PARTITION BT RANGE (field3)
(
PARTITION sx1991 VALUES LESS THAN (TO_DATE('1991'),'YYYY')) TABLESPACE ts0 NOLOGGING,
PARTITION sx1992 VALUES LESS THAN (TO_DATE('1992'),'YYYY')) TABLESPACE ts1 NOLOGGING,
PARTITION sx1993 VALUES LESS THAN (TO_DATE('1993'),'YYYY')) TABLESPACE ts2 NOLOGGING,
);
You can get more information from Oracle Manual. Hope this will help you . Thanks
|
|
|