How can i use a comparison operaton in a select i.e.
select 1=2 from dual;
Expecting a boolean result
This request give me an error 00923. 00000 - "FROM keyword not found where expected"
How can i use a comparison operaton in a select i.e.
select 1=2 from dual;
Expecting a boolean result
This request give me an error 00923. 00000 - "FROM keyword not found where expected"
Yes, you can use the comparison operators but in the clauses where a boolean value is expected, e.g. WHERE
, HAVING
etc.
An reprodicible example without using the functions and case
operator:
select (
select 'true' from dual where 1=2 union all
select 'false' from dual
order by 1 desc fetch first row only) "boolresult"
from dual
/
boolresult
----------------
false