Thanks for the question, Alok.
Asked: September 20, 2016 - 10:21 am UTC
Last updated: September 29, 2016 - 10:46 am UTC
Version: Oracle 11g
Viewed 1000+ times
You Asked
Hi Tom,
I have doubt regarding one of the scenarios in which boolean is used.
For example,
v_bool boolean:=TRUE;
If I am doing in an expression:
v_bool = TRUE then its fine
but if I am writing
v_bool is TRUE--- its throwing error
Please explain how these two cases are different.
Thanks,
Alok
and Connor said...
"is" is only appropriate for certain options, eg is null, is not null, is a set etc.
But you dont need '=' because it is *already* a boolean.
eg
declare
x boolean := true;
begin
if x then <=====
...
Rating
(1 rating)
Is this answer out of date? If it is, please let us know via a Comment