Mario Weilguni wrote:
> Yes this is completly different. Oracle decode works like this:
> 
> decode(value, choice1, result1, choice 2, result2, ......,
> default_result)
> 
> it works this way:  case
>   when value=choice1 then result1 when value=choice2 then result2
>   ....
>   else default_result end

Yes, it would be nice to be able turn these on just for portability with
Oracle queries.

> The nice part is it has an varying number of arguments, and can
> used within "sort". Very useful sometimes.

With our CASE, you create a column using the CASE, then ODER BY on that
column.

> Another one very useful oracle function is "nvl", the same like
> "coalesce", but a lot easier to write :-)

Yes, another nice portability thing if it could be enabled/disabled.

--
  Bruce Momjian                        |  http://candle.pha.pa.us
  [EMAIL PROTECTED]               |  (610) 359-1001
  +  If your life is a hard drive,     |  13 Roberts Road
  +  Christ can be your backup.        |  Newtown Square, Pennsylvania 19073

---------------------------(end of broadcast)---------------------------
TIP 4: Don't 'kill -9' the postmaster

Reply via email to