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 (December 2002, week 2)Back to main SAS-L pageJoin or leave SAS-L (or change settings)ReplyPost a new messageSearchProportional fontNon-proportional font
Date:         Tue, 10 Dec 2002 14:34:17 -0500
Reply-To:     Marianne Whitlock <WHITLOM1@WESTAT.COM>
Sender:       "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From:         Marianne Whitlock <WHITLOM1@WESTAT.COM>
Subject:      Re: recruiting cheesy, sleasy SAS tricks
Comments: To: "michael@BASSETTCONSULTING.COM" <michael@BASSETTCONSULTING.COM>
Content-Type: text/plain; charset="iso-8859-1"

I didn't see the earlier thread, but the ATTRIB statement change the length in the code below:

data a; CharVar = "XYZ" ; run; proc sql ; select length from dictionary.columns where libname="WORK" and upcase(memname) = "A" and upcase(name) = "CHARVAR" ; quit; data b; attrib CharVar length= $ 4; set a; CharVar = "ABCD" ; run; proc sql ; select length from dictionary.columns where libname="WORK" and upcase(memname) = "B" and upcase(name) = "CHARVAR" ; quit;

-----Original Message----- From: Michael L. Davis [mailto:michael@BASSETTCONSULTING.COM] Sent: Tuesday, December 10, 2002 1:56 PM To: SAS-L@LISTSERV.UGA.EDU Subject: recruiting cheesy, sleasy SAS tricks

BTW, thanks to all for the help last week with regards to reordering the PDV. Unfortunately, the friend for whom I was trolling wanted as easy a method as the RETAIN statement. The ATTRIB statement was to change the length of a variable brought in by a SET statement. So combining the RETAIN and ATTRIB statements did not work (the length was not changed by the ATTRIB statement).


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