-
i have an existing primary key constraint, how can i add another column in this constraint(there are two existing column on this constraint)? do i need to drop this one and create another one ? how about the index referred to this contraint what will happen if i delete it ? i tried to delete it using dba studio but there's no option for it.
thanks in advance.
-
I don't Know about that u can add column to primary key constraint.
But one solution may be
desable primary key constraint
create another PK index including all columuns that u want.
and drop previous disable Pk constraint
try it out
Kuckoo
-
alter table tblname drop constraint pkname;
alter table tblname add constraint pkname primary key(col1,col2);
the old primary index will be deleted and a new index will created
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|