I learned about the Partition Table Technology in Oracle today. Now I want to save the statement for creating a partition table here!
SQL> conn system/windows @ study
Connected.
SQL> create tablespace test datafile 'd: \ oracle \ product \ 10.2.0 \ oradata \ study \ tes
T. dbf 'size 100 M autoextend on;
The tablespace has been created.
SQL> create tablespace test1 datafile 'd: \ oracle \ product \ 10.2.0 \ oradata \ study \ te
St1.dbf 'size 100 M autoextend on;
The tablespace has been created.
SQL> create user test identified by windows default tablespace test;
The user has been created.
SQL> grant connect, resource to test;
Authorization successful.
SQL> commit;
Submitted.
SQL> conn test/windows @ study
Connected.
SQL> create table t_partition_range (id number, name varchar2 (50) partition by r
Ange (id) (partition t_range_p1 values less than (10) tablespace test, partition t _
Range_p2 values less than (20) tablespace test1, partition t_range_p3 values less
Than (30) tablespace users, partition t_range_pmax values less than (maxvalue) t
Ablespace users );
The table has been created.
SQL> insert into t_partition_range values (1, 'www ');
One row has been created.
SQL> insert into t_partition_range values (20, 'www ');
One row has been created.
SQL> insert into t_partition_range values (22, 'www ');
One row has been created.
SQL> insert into t_partition_range values (33, 'www ');
One row has been created.
SQL> insert into t_partition_range values (44, 'www ');
One row has been created.
SQL> commit;
Submitted.
SQL> select * from t_partition_range;
ID NAME
------------------------------------------------------------
1 wwww
20 wwww
22 wwww
33 wwww
44 wwww
SQL> select rowid, t. * from t_partition_range t;
ROWID ID NAME
------------------------------------------------------------------------------
AAAMqpAAFAAAAAWAAA 1 wwww
AAAMqrAAEAAAABGAAA 20 wwww
AAAMqrAAEAAAABGAAB 22 wwww
Aaamqsaaeaaaabaaa 33 wwww
AAAMqsAAEAAAABOAAB 44 wwww
SQL>