Hello,
I'm trying to do an assertion in which a customer must be sent one or more messages in my database. However, in Oracle, I've noticed you can't do assertions but you can have the similar outcome with the use of triggers.
Currently I have:
CREATE ASSERTION each_cust_get_msg
CHECK (NOT EXISTS (
SELECT * FROM Customer Cust
WHERE NOT EXISTS (
SELECT * FROM SendMsg Send
WHERE Cust.email = Send.email)))
Can anybody please help me turn the above assertion to work in Oracle? It doesn't necessarily have to be a trigger.
Any help is appreciated.
Thanks.
Edited by: user13150012 on May 27, 2012 6:48 AM