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

Home -> Community -> Mailing Lists -> Oracle-L -> Re: number only

Re: number only

From: Stephane Faroult <sfaroult_at_roughsea.com>
Date: Wed, 30 Jun 2004 15:38:54 +0200
Message-Id: <200406301338.i5UDcsW22651@noc.nexlink.net>


 RTF SQL Reference, functions, TRANSLATE(). With a pinch of DECODE(LENGTH(), 0, 999, ...) it should do.
Regards,

Stephane Faroult

On Wed, 30 Jun 2004 14:34 , 'Oracle' <oracle_list_at_hotmail.com> sent:

I have a column with data such as :

abc123
123
abcde

I want to write a query which returns only numbers from the column , if there are none, then default to 999
So i would have:

123
123
999

Any ideas on the syntax?

Thanks



Please see the official ORACLE-L FAQ: http://www.orafaq.com[1]

To unsubscribe send email to: oracle-l-request_at_freelists.org[2] put 'unsubscribe' in the subject line.
--

Archives are at http://www.freelists.org/archives/oracle-l/[3] FAQ is at http://www.freelists.org/help/fom-serve/cache/1.html[4]
Received on Wed Jun 30 2004 - 08:37:25 CDT

Original text of this message

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