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!

Can error "ORA-01442" be turned off?

WestDraytonDec 17 2010 — edited Dec 17 2010
I have alter statement like:
ALTER table T MODIFY
(
  CODE                           NUMBER(20) not null,
  NAME                           VARCHAR2(80) not null,
...
);
The column "T.Code" actually already is "NUMBER(20) not null", so my alter-statement doesn't actually introduce anything new for that column, but column "T.Name" gets something new, for example it was "VARCHAR2(70) not null" and now the field length will increase a little.
I have more columns in my alter-statement. I want the alter-statement to succeed. I don't feel anything bad that i don't introduce anything new for some columns. But database engine thinks somehow differently and fires "ORA-01442" error and my whole alter-statement fails.
Can i somehow turn off that error?

ORA-01442:	column to be modified to NOT NULL is already NOT NULL
Cause:	An ALTER TABLE MODIFY statement attempted to change a column specification unnecessarily, from NOT NULL to NOT NULL.
Action:	No action required. 
(Oracle 10g, Linux OS)
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Jan 14 2011
Added on Dec 17 2010
5 comments
872 views