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!

ORA-01779:, But I have unique key????

443882Sep 5 2005 — edited Sep 5 2005
I 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?
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Oct 3 2005
Added on Sep 5 2005
4 comments
463 views