var sidebar_align = 'right';
var content_container_margin = parseInt('290px');
var sidebar_width = parseInt('270px');
Unanswered: Differences in 8i / 9i CASE expressions
The following query leads to ORA-00932 inconsistent datatypes on 8i, while it works fine with Oracle 9i.
SELECT CASE WHEN <something>
THEN (date1 - date2)
ELSE (date1 - date2 + 1 / 24) END
My initial observations -
1. The Oracle 8i/9i SQL reference says -
The datatype of all the THEN, ELSE clauses should be the same, which
should be the same as the datatype of the first THEN clause.
2. But i confirmed (through an insert stmt) that date1-date2 is indeed a
number, even date1 - date2 + 1 / 24 is a number, so they are in sync.
3. Please note that, adding a to_number to the first THEN clause, makes
the query work fine with both 8i and 9i.
I get the same. It would seem to be a bug in 8i that got fixed in 9i, wouldn't it?