1.将表置为READ ONLY
SQL> alter table T1 READ ONLY;
Table altered.
SQL> create index t1_index on T1 (id);
Index created.
SQL> alter table T1 DROP COLUMN NAME;
alter table T1 DROP COLUMN NAME
*
ERROR at line 1:
ORA-12081: update operation not allowed on table "SYS"."T1"
SQL> alter table T1 set unused(name);
alter table T1 set unused(name)
*
ERROR at line 1:
ORA-12081: update operation not allowed on table "SYS"."T1"
SQL> truncate TABLE T1;
truncate TABLE T1
*
ERROR at line 1:
ORA-12081: update operation not allowed on table "SYS"."T1"
恢复表read write
SQL> alter table T1 READ write;
Table altered.
版权声明:本文为博主原创文章,未经博主允许不得转载。
oracle