Hello,
Testing the ability to define a PDB partitioning using the container map, I see that work fine for select statements, but not for Updates.
Let me show:
I've the emp table partitioned across 3 PDBS:
SQL> select empno, deptno , con_id from emp;
EMPNO DEPTNO CON_ID
----- ------ ------
7782 10 16
7839 10 16
7934 10 16
7369 20 17
7566 20 17
7788 20 17
7876 20 17
7902 20 17
7499 30 15
7521 30 15
7654 30 15
7698 30 15
7844 30 15
7900 30 15
14 rows selected.
Now, If I use the partitiong key to filter:
SQL> select empno, deptno , con_id from emp where deptno=10;
EMPNO DEPTNO CON_ID
----- ------ ------
7782 10 16
7839 10 16
7934 10 16
This work fine.
However If I try :
SQL> update emp set sal=sal*10 where deptno=10;
0 rows updated. ---> No Rows updated,
To do this, I need indicate CONTAINERS CLAUSE:
SQL> update containers(emp) set sal=sal*1.10 where con_id = 16;
3 rows updated.
Same, happen with delete.
Also, I try to update the partitioning key to see if the rows move to another PDB.
update containers(emp) set deptno=10 where con_id=17
*
ERROR at line 1:
ORA-02291: integrity constraint (SCOTT.FK_DEPTNO) violated - parent key not found
ORA-02063: preceding line from RESEARCH
Is this a restricction of this reléase, or I need set any parameter to allow update operations?
Thanks
Arturo