Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.misc -> Re: Question on Check Constraints
A copy of this was sent to "Kevin Donovan" <kdonovan_at_brainiac.com>
(if that email address didn't require changing)
On Mon, 8 Mar 1999 14:20:52 -0500, you wrote:
>I have a question regarding the construction of check constraints in Oracle
>8.X. Here is the situation: I have 2 tables in an instance, both have the
>same name but different owners. I have a business rule that states that the
>same key cannot exist in both these tables. Is it possible with a check
>constraint to enforce this. If it is, any tips you have on creating this
>would be very helpful.
>
>Thanks
>
>Kevin
>
>
No, you might be able to do this with a trigger but it is trickier then it looks.
If you use a sequence number as the primary key and use the same sequence for both tables -- it'll do the trick as well.
Thomas Kyte
tkyte_at_us.oracle.com
Oracle Service Industries
Reston, VA USA
--
http://govt.us.oracle.com/ -- downloadable utilities