Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Mailing Lists -> Oracle-L -> RE: DECODE or not to DECODE
Thanks To all for the support!
I managed to use a combination of thesuggestions which worked great!
Denham
-----Original Message-----
Sent: Monday, August 04, 2003 4:24 PM
To: Multiple recipients of list ORACLE-L
Hello Listers,
I need some help please,
I am trying to create a DECODE statement, on a date column and looks
something like this, but does not work.
SELECT COL1,
COL2, DECODE((SYSDATE - COL_DATE), <= 30, '30_days', NULL) Days30, DECODE((SYSDATE - COL_DATE), (between 31 and 60), '60 Days',NULL) Days60,
TIA
Denham Eva
Oracle DBA
For more information please visit www.marshalsoftware.com
#####################################################################################
Any views expressed in this message are those of the individual sender,
except where
the message states otherwise and the sender is authorized to state them to
be the
views of any such entity.
Thank You.
--
Please see the official ORACLE-L FAQ: http://www.orafaq.net
--
Author: Denham Eva
INET: EvaD_at_TFMC.co.za
Fat City Network Services -- 858-538-5051 http://www.fatcity.com San Diego, California -- Mailing list and web hosting services ---------------------------------------------------------------------To REMOVE yourself from this mailing list, send an E-Mail message to: ListGuru_at_fatcity.com (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).
For more information please visit www.marshalsoftware.com
For more information please visit www.marshalsoftware.com
#####################################################################################Note:
Any views expressed in this message are those of the individual sender, except where the message states otherwise and the sender is authorized to state them to be the views of any such entity.
Thank You.
--
Please see the official ORACLE-L FAQ: http://www.orafaq.net
--
Author: Denham Eva
INET: EvaD_at_TFMC.co.za
Fat City Network Services -- 858-538-5051 http://www.fatcity.com San Diego, California -- Mailing list and web hosting services ---------------------------------------------------------------------To REMOVE yourself from this mailing list, send an E-Mail message to: ListGuru_at_fatcity.com (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). Received on Tue Aug 05 2003 - 09:04:23 CDT
![]() |
![]() |