ORA-14402: updating partition key column would cause a partition change

来源:互联网 发布:淘宝匿名购买好不好 编辑:程序博客网 时间:2024/05/29 16:25

问题描述

        当更新分区表的分区键时,会出现ORA-14402错误。


演示:

表t_order_photo 是按照EDATE为分区键的分区表。

SQL> update t_order_photo t  2  set t.edate=sysdate,editor='Alen',photo_status=0  3  where t.id=611;update t_order_photo t       *ERROR at line 1:ORA-14402: updating partition key column would cause a partition change


解决办法

       对该表启用行移动。

演示:

SQL> alter table t_order_photo enable row movement;Table altered.SQL> update t_order_photo t  2  set t.edate=sysdate,editor='Alen',photo_status=0  3  where t.id=611;1 row updated.SQL>



原创粉丝点击