|
A partition key:
Consists of an ordered list of 1 to 16 columns
Cannot contain a LEVEL, ROWID, or MLSLABEL pseudocolumn or a column of
Can contain columns that are NULLable
Tables can be partitioned into up to 64,000 separate partitions. Any table can be
partitioned except those tables containing columns with LONG or LONG RAW
datatypes. You can, however, use tables containing columns with CLOB or BLOB
datatypes.
您看:你先把表备份一下,然后删除索引,再删除表;然后重新建表,把STORAGE参数都改一下,再重新建索引,性能会有很大改进吧。而且,分区的时候可以利用表空间,把他们存在多个磁盘上;把表和索引也分别存在不同的磁盘上。
When using range partitioning, consider the following rules:
Each partition has a VALUES LESS THAN clause, which specifies a noninclusive
upper bound for the partitions. Any values of the partition key equal to or
higher than this literal are added to the next higher partition.
All partitions, except the first, have an implicit lower bound specified by the
VALUES LESS THAN clause on the previous partition.
A MAXVALUE literal can be defined for the highest partition. MAXVALUE
represents a virtual infinite value that sorts higher than any other possible value
for the partition key, including the null value.
A typical example is given in the following section. The statement creates a table
(sales_range) that is range partitioned on the sales_date field.
Range Partitioning Example
CREATE TABLE sales_range
(salesman_id NUMBER(5),
salesman_name VARCHAR2(30),
sales_amount NUMBER(10),
sales_date DATE)
PARTITION BY RANGE(sales_date)
(
PARTITION sales_jan2000 VALUES LESS THAN(TO_DATE('02/01/2000','DD/MM/YYYY')),
PARTITION sales_feb2000 VALUES LESS THAN(TO_DATE('03/01/2000','DD/MM/YYYY')),
PARTITION sales_mar2000 VALUES LESS THAN(TO_DATE('04/01/2000','DD/MM/YYYY')),
PARTITION sales_apr2000 VALUES LESS THAN(TO_DATE('05/01/2000','DD/MM/YYYY')); |
|