Skip to Main Content

SQL & PL/SQL

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

How to change (decrease) primary key column length?

14137May 2 2002
Hi all,

I have plenty of data in the table and I need to decrease the primary key column from CHAR(17) to CHAR(13).
I try to use:
ALTER TABLE xx MODIFY (prmy_key (13));

but Oracle give:
ERROR at line 1:
ORA-01441: column to be modified must be empty to decrease column length

Can anyone give me advice on what is the best way to decrease column length? Thanks in advance for your help.
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Jun 1 2002
Added on May 2 2002
10 comments
1,001 views