Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.tools -> Re: Null select
On Fri, 12 May 2000 13:22:24 GMT, "Kram" <kram_at_biosys.net> wrote:
>I am performing the select statement which includes formatting a credit card
>number with "-". However, the problem is if the record returns a null the
>"-" the statement still returns "---" is there a better way to perform this?
>
>select crcname,
>crcexp,
>rpad(substr(crcardno,1,4) || '-' || substr(crcardno,5,4) || '-' ||
>substr(crcardno,9,4) || '-' || substr(crcardno,13,4),25,' ')
>from crcard
WHERE crcardno IS NOT NULL;
Brian Received on Fri May 12 2000 - 00:00:00 CDT
![]() |
![]() |