Gyula,

I understand, that you want to apply DECODE function to some local variables
in your pl/sql block (and not to some columns in some table).

The trick is: you can always run DECODE() against 'dual' table:

select DECODE(base_expr, compare1, value1, compare2, value2,... default )
into local_variable_out from dual;

In this case 'base_expr' does not have to reference any column in any table.

Igor Neyman, OCP DBA
Perceptron, Inc.
(734)414-4627
[EMAIL PROTECTED]


----- Original Message -----
To: "Multiple recipients of list ORACLE-L" <[EMAIL PROTECTED]>
Sent: Thursday, May 17, 2001 5:26 AM


> Hi Gurus !
>
>
> Is there any function that can be used in PL/SQL and  just works the way
as
> DECODE does in Sql?
>
> Thanks in Advance
>
> Gyula
> --
> Please see the official ORACLE-L FAQ: http://www.orafaq.com
> --
> Author: Andor, Gyula
>   INET: [EMAIL PROTECTED]
>
> Fat City Network Services    -- (858) 538-5051  FAX: (858) 538-5051
> San Diego, California        -- Public Internet access / Mailing Lists
> --------------------------------------------------------------------
> To REMOVE yourself from this mailing list, send an E-Mail message
> to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in
> the message BODY, include a line containing: UNSUB ORACLE-L
> (or the name of mailing list you want to be removed from).  You may
> also send the HELP command for other information (like subscribing).

-- 
Please see the official ORACLE-L FAQ: http://www.orafaq.com
-- 
Author: Igor Neyman
  INET: [EMAIL PROTECTED]

Fat City Network Services    -- (858) 538-5051  FAX: (858) 538-5051
San Diego, California        -- Public Internet access / Mailing Lists
--------------------------------------------------------------------
To REMOVE yourself from this mailing list, send an E-Mail message
to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in
the message BODY, include a line containing: UNSUB ORACLE-L
(or the name of mailing list you want to be removed from).  You may
also send the HELP command for other information (like subscribing).

Reply via email to