ORA-01779:, But I have unique key????
443882Sep 5 2005 — edited Sep 5 2005I have the tables
TABLE1: ID (PK), DATA_DESTI
TABLE2: ID, TABLE_SOURCE, DATA_DESTI_NEW
Then I execute this UPDATE
UPDATE
(
SELECT
TABLE2.DATA_DESTI_NEW, TABLE1.DATA_DESTI
FROM ODS.TABLE1,
ODS.TABLE2
WHERE
TABLE1.ID = TABLE2.ID and TABLE2.TABLE_SOURCE = 1
)
SET DATA_DESTI = DATA_DESTI_NEW
And I receive the error
ORA-01779: cannot modify a column which maps to a non key-preserved table
Note: I have UNIQUE Constraint ON Table2 Fields (ID, TABLE_SOURCE)... Then..., Why I receive the error?