Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.server -> Help - Funny Constraint
Hi All,
I want to enforce the following.
Table C1 has two fields F1, F2
I want to prevent the update of field F1 if the value of F2 exists in another table C2.
So if
C1.F1 C1.F2 1 11 2 12
and
C2.FF
11
then the value 1 in C1 shou1d not be updatable but the value 2 should be (as there is no value of 12 in C2).
I can use a trigger but how can I stop the update from happenning based on a value the trigger works out ?
Altenatively can I somehow use a CHECK_CONSTRAINT ?
Thanks v. much
Kevin. Received on Fri Aug 28 1998 - 05:41:13 CDT
![]() |
![]() |