Date: Thu, 20 Mar 2008 07:27:35 -0500
Reply-To: "data _null_," <datanull@GMAIL.COM>
Sender: "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From: "data _null_," <datanull@GMAIL.COM>
Subject: Re: extracting the month from a date in date9. format
In-Reply-To: <1bb98f37-b2dd-440f-907f-30bb6a841ed2@s12g2000prg.googlegroups.com>
Content-Type: text/plain; charset=ISO-8859-1
Use the FORMAT WORDDATE3.
data _null_;
do i = today() to today()+356 by 30;
month=put(i,worddate3.);
putlog 'NOTE: ' I=date9. I=worddate3. month=;
end;
run;
On Thu, Mar 20, 2008 at 7:07 AM, shashi <shashi2707@gmail.com> wrote:
> Hi,
> How do we extract the month from a date in date9. format in SAS?
> example: from 20mar2008, I want the month as 'mar' not as 3.
>
|