Date: Tue, 15 Feb 2005 13:03:08 -0500
Reply-To: "Howard Schreier <hs AT dc-sug DOT org>" <nospam@HOWLES.COM>
Sender: "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From: "Howard Schreier <hs AT dc-sug DOT org>" <nospam@HOWLES.COM>
Subject: Re: Convert ZIP into character and add missing zeroes infront
However, there is the SSNw. format, which was provided specifically for
U.S. social security numbers stored as numerics.
The Z5. format does the job for U.S. zip codes, but it was not designed for
that purpose alone. If you have 9-digit zips stored as numerics, and you
want them displayed with the customary hyphen between the 5th and 6th
digits, it won't help you.
On Tue, 15 Feb 2005 09:23:20 -0800, Choate, Paul@DDS <pchoate@DDS.CA.GOV>
>Karen - you need to look into picture formats under Proc Format - SAS
>provides examples of what you want.
>DDS Data Extraction
>From: SAS(r) Discussion [mailto:SAS-L@LISTSERV.UGA.EDU] On Behalf Of Karen
>Sent: Tuesday, February 15, 2005 7:14 AM
>Subject: Re: Convert ZIP into character and add missing zeroes infront
>Is there a similar format that will do the same thing for Social Security
>On Mon, 14 Feb 2005 13:00:03 -0800, Choate, Paul@DDS <pchoate@DDS.CA.GOV>
>>Try the z5. format - it writes numbers to characters with leading zeros.
>>DDS Data Extraction
>>From: SAS(r) Discussion [mailto:SAS-L@LISTSERV.UGA.EDU] On Behalf Of
>>Sent: Monday, February 14, 2005 12:58 PM
>>Subject: Convert ZIP into character and add missing zeroes infront
>>Hello SAS experts,
>>I have ZIP codes in numeric form like 7001 (it's missing a zero infront to
>>make it a legitimate 5-digit zip code), 60073(has 5- digits, it's fine),
>>etc. I would like to convert my numeric ZIPS into characters and at the
>>time add leading zeroes to make them legitimate 5-digits ZIPs. How do I do
>>that? Thnaks much.
>>I would like ZIP to become a character variable like
>>Sign-up for Ads Free at Mail.com