Re: Problem in checking conditions

From: Peter Schneider <pschneider1968_at_googlemail.com>
Date: Sun, 09 Feb 2014 10:21:10 +0100
Message-ID: <ld7hde$7of$1_at_news.albasani.net>


Am 08.02.2014 20:38, schrieb Karthick Ravi:
> Hello Sir,
>
> I'm using Oracle 10g for Educational purpose. I have only one table with five columns namely cusid,name,deposits and loan. Now when i create a check constrain using create assertion command i get error, When searching about it on web i found that create assertion command was in SQL-92 and no more in use. Was that true? can't we use assertions in Oracle 10g or Above?
>
> If there is any alternate way to check,
> (i) The total loan provided by loan should be always less than the total deposits made.
> (ii) If there is an alternate way Please provide the basic code here.

In Oracle there is no "CREATE ASSERTION". You create a CHECK constraint.

http://docs.oracle.com/cd/B19306_01/server.102/b14200/clauses002.htm#CJAEDFIB

http://docs.oracle.com/cd/B19306_01/server.102/b14200/clauses002.htm#i1002719

Regards
Peter

-- 
Climb the mountain not to plant your flag, but to embrace the challenge,
enjoy the air and behold the view. Climb it so you can see the world,
not so the world can see you.                    -- David McCullough Jr.
Received on Sun Feb 09 2014 - 10:21:10 CET

Original text of this message