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 -> Re: Please Help! Formatting Numbers with Leading Zeros

Re: Please Help! Formatting Numbers with Leading Zeros

From: David Russell <dbruce_at_kreative.net>
Date: Tue, 25 May 1999 23:16:34 GMT
Message-ID: <374b2e50.1213705@news>

don't think I would have made it numeric in the first place... what about nine and eleven digit zips? how would you handle the dash and space? how do you store phone numbers?

Now, to answer your question. In your SQL script, do the following format statement:

column zip_code format 00009

and your data will be returned with the leading zeros.

David Russell

On Mon, 24 May 1999 15:25:26 -0700, Sussette Blasa <stblasa_at_earthlink.net> wrote:

>Hi--hope somone can help...I've been trying to find a way to format
>postal/zip code. The field is a number datatype. For example the postal
>code for Westport, CT is 06880. However, when a run a query like this:
>
>SELECT POSTAL_CODE FROM DEALER_TABLE
>WHERE CITY = 'WESTPORT'
>
>The output comes out with " 6880". I want the output to return with the
>five-digit number "06880" instead.
>
>Any help would be appreciated!
>
>--Sussette
>
>
Received on Tue May 25 1999 - 18:16:34 CDT

Original text of this message

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