-- Create table
create table testTable
(
tjsj DATE not null
)tablespace tablespace1
PARTITION BY RANGE(TJSJ)
INTERVAL (NUMTODSINTERVAL(1,'DAY')) store in ( tablespace2)
(
PARTITION p_20190101 values LESS THAN (TO_DATE('2019-01-01 00:00:00', 'SYYYY-MM-DD HH24:MI:SS')) tablespace tablespace2
);
-- Add comments to the columns
comment on column testTable.tjsj
is '時間 YYYYMMDD';
-- Create/Recreate primary, unique and foreign key constraints
alter table testTable
add constraint PK_xxxx primary key (TJSJ)
using index
tablespace tablespace3
pctfree 10
initrans 2
maxtrans 255
storage
(
initial 64K
next 1M
minextents 1
maxextents unlimited
);