Forum OpenACS Q&A: Re: oracle support for case when...

Collapse
Posted by Don Baccus on
I couldn't get it to work in 8.1.6 but a quick search on Google clued me in to why that might be true:

"CASE was introdiced in Oracle 8i, but only in SQL, not in PL/SQL.
It is available both in SQL and PL/SQL in Oracle 9i."

I was probably trying it in a PL/SQL statement ...

I have 8.1.6 here I'll try to remember to test it in SQL, would be nice to get rid of some of the Oracle-specific queries in the toolket!

Collapse
Posted by Brian Fenton on
Tom Kyte talks about this on his site and shows a workaround using dynamic SQL. Here's one example: http://asktom.oracle.com/pls/ask/f?p=4950:8:::::F4950_P8_DISPLAYID:4333097088785