-
Hi all!
Query:
1.I have a column STORE_NO number(2) being combined Primary key and
Foreign Keys along with other columns in the Parent and Child
Tables.Both primary and Foreign Keys constraints are defined for them!
Now If I would like to change the data type of STORE_NO from number(2)
to varchar2(4),how should we be able to do it considering the above
constraints and the STORE_NO column contains datas therein!
Tha table is as under:
SQL> desc t_str_code_master
Name Null? Type
------------------------------- -------- ----
COMPANY_CODE NUMBER(2)
STORE_DESC NOT NULL VARCHAR2(50)
LOCATION VARCHAR2(50)
STORE_NO NUMBER(2)
SQL> alter table t_str_code_master
2 modify store_no varchar2(4);
modify store_no varchar2(4)
*
ERROR at line 2:
ORA-02267: column type incompatible with referenced column type
What and where should I look for to resolve the above error!
Thanks&Regards,
Amit.
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
|