LISTSERV at the University of Georgia
Menubar Imagemap
Home Browse Manage Request Manuals Register
Previous messageNext messagePrevious in topicNext in topicPrevious by same authorNext by same authorPrevious page (May 2007, week 2)Back to main SAS-L pageJoin or leave SAS-L (or change settings)ReplyPost a new messageSearchProportional fontNon-proportional font
Date:         Mon, 14 May 2007 13:59:11 +0000
Reply-To:     toby dunn <tobydunn@HOTMAIL.COM>
Sender:       "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From:         toby dunn <tobydunn@HOTMAIL.COM>
Subject:      Re: how to extract from a numeric value?
Comments: To: joey_qf@163.COM
In-Reply-To:  <1179150814.820746.59560@h2g2000hsg.googlegroups.com>
Content-Type: text/plain; format=flowed

sorry that second assignment statement should have been :

Year = Input( Substr( Put( Date , 8. -L ) , 1 , 4 ) , 8. ) ;

Toby Dunn

On the other hand, you have different fingers. ~ LCG

The early bird may get the worm, but the second mouse gets the cheese in the trap. ~ LCG

What happens if you get scared half to death, twice? ~ LCG

From: Fei <joey_qf@163.COM> Reply-To: Fei <joey_qf@163.COM> To: SAS-L@LISTSERV.UGA.EDU Subject: how to extract from a numeric value? Date: Mon, 14 May 2007 06:53:34 -0700

Hi guys:

I have a variable yyyymm - year and month, which is a numeric variable, like: 199101 199102

I just want year now...I have tried to used "substr", but it returns a character. I want a numbric value...is there any way?

Thanks

Fei

_________________________________________________________________ PC Magazine’s 2007 editors’ choice for best Web mail—award-winning Windows Live Hotmail. http://imagine-windowslive.com/hotmail/?locale=en-us&ocid=TXT_TAGHM_migration_HM_mini_pcmag_0507


Back to: Top of message | Previous page | Main SAS-L page