subpartition sub1 values('01'),subpartition sub2 values('02'), subpartition sub3 values('03'),subpartition sub4 values('04'), subpartition sub5 values('05'),subpartition sub6 values('06'), subpartition sub7 values('07'),subpartition sub8 values('08'), subpartition sub9 values('09'),s...
SUBPARTITION BY HASH(column_list) SUBPARTITIONS <number_of_subpartitions> STORE IN(<tablespace_name_list>, < >, < >,...) ( PARTITION <parition_name1> VALUES LESS THAN(<VALUE>) ( SUBPARTITION <partition_name> TABLESPACE <tablespace_name>, SUBPARTITION <partition_name> TABLESPACE <tablespace_...
l subpartition:子分区方式,有两处: n Subpartition_by_list:语法与 list 分区完全相同,只不过把关键字 partition 换成 subpartition n Subpartition_by_hash:语法与 hash 分区完全相同,只不过把关键字 partition 换成 subpartition l partition:分区名称; l range_partition_values_clause:与 range 分区范围值的语法...
partition by range(transaction_date)subpartition by hash(transaction_id) subpartitions3store in (dinya_space07,dinya_space08,dinya_space09) ( partition part_07 values less than(to_date('2006-01-01','yyyy-mm-dd')), partition part_08 values less than(to_date('2010-01-01','yyyy-mm-dd'...
列表和HASH组合分区 我们也可以使用列表和HASH做组合进行分区,建表sql如下: create table t_operate_log ( id number(7), type varchar2(10), op_time date ) PARTITION BY list(type) SUBPARTITION BY HASH (id) ( PARTITION t_operate_log_type_add VALUES('add') ...
partition by hash(id) ( partition par_01 tablespace TBS_TEST_1, --创建par_01分区 partition par_02 tablespace TBS_TEST_2 --创建par_02分区 ); 在为商品零售表ware_retail_part3创建了两个HASH分区之后,接下来向该表中插入一条记录。 --向表ware_retail_part3中插入一条记录 ...
CREATETABLErange_hash_example( range_column_keyint, hash_column_keyINT, DATAVARCHAR2(20) ) PARTITIONBYRANGE(range_column_key) SUBPARTITIONBYHASH(hash_column_key) SUBPARTITIONS2( PARTITION part_1VALUESLESS THAN (100000000) ( SUBPARTITION part_1_sub_1, SUBPARTITION...
partition by range(part_date) subpartition by hash(part_id) subpartitions 2 store in(dw1,dw2) ( partition part_01 values less than(to_date('2006-01-01','yyyy-mm-dd')) tablespace dw1, partition part_02 values less than(to_date('2007-01-01','yyyy-mm-dd')) tablespace dw2, ...
先id范围分区, 在对子分区按照hash分区, 根据name列的hash值确定该行分布在tbsp1 或 tbsp2的某个表空间上 create tableAAA(id number primary key,namevarchar2(20),sexvarchar2(2))partitionbyrange(id)--id 做范围分区 subpartition byhash(name)--name做hash分区 ...
subpartition by hash(name) --hash子分区 subpartitions 2 store in(tbsp_1,tbsp_2) --存储在两个不同的命名空间中 ( partition par1 values less than(5000), partition par2 values less than(10000), partition par3 values less than(maxvalue) ); ...