Alter an Existing PPI

Database

Alter an Existing PPI

Hi All,


I have the following table defined :

person_car_dtl

p_num bigint

p_dt date

p_car_num varchar(100)

primary index (p_num) 

PARTITION BY RANGE_N(p_dt  BETWEEN DATE '2002-01-01' AND DATE '2010-12-31' EACH INTERVAL '1' YEAR ,

DATE '2011-01-01' AND DATE '2013-12-31' EACH INTERVAL '1' MONTH ,  NO RANGE);

Now, since the partitioning by month is implemented till 2013 only, i want to change it to 2021 or some other year.

Is it possible to do so without dropping the table ? If yes, can you please suggest the syntax.

Tags (3)
1 REPLY

Re: Alter an Existing PPI

Figured out the sytax and was able to alter PPI using the following command :

alter table person_car_dtl

MODIFY PRIMARY INDEX (p_num)

ADD RANGE BETWEEN DATE '2014-01-01' AND DATE '2021-12-31' EACH INTERVAL '1' MONTH;