Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.misc -> Oracle 8i SQL Statement

Oracle 8i SQL Statement

From: Kent Prokopy <kent_prokopy_at_stream.com>
Date: 19 Sep 2003 04:53:54 -0700
Message-ID: <ec8c1578.0309190353.28346e7d@posting.google.com>


When using the DECODE function, is there any way of passing it the IN() clause?

Example:
DECODE(FIELDNAME,IN(1,2,3),TRUE,FALSE) This returnning TRUE if the values of 1, 2 or 3 are found. So far the only way I can get this to work is as follows:

DECODE(FIELDNAME,1,TRUE,2,TRUE,3,TRUE,FALSE) "This leaving a lot of room for typo errors."

Thank you.
Kent Prokopy Received on Fri Sep 19 2003 - 06:53:54 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US