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 (July 2009, week 3)Back to main SAS-L pageJoin or leave SAS-L (or change settings)ReplyPost a new messageSearchProportional fontNon-proportional font
Date:   Wed, 15 Jul 2009 14:17:43 -0500
Reply-To:   Joe Matise <snoopy369@GMAIL.COM>
Sender:   "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From:   Joe Matise <snoopy369@GMAIL.COM>
Subject:   Re: Query around label
Comments:   To: rajat.mathur@diamondconsultants.com
In-Reply-To:   <20090715115839.6E864968@resin13.mta.everyone.net>
Content-Type:   text/plain; charset=ISO-8859-1

I think this would be easier...

data test; set sashelp.class; x=1; run;

data _null_; call execute("proc datasets library=work nolist; modify test; label x="||vlabel(age)||";quit;"); stop; set test; run;

Of course,

On Wed, Jul 15, 2009 at 1:58 PM, Mary <mlhoward@avalon.net> wrote:

> That's a bit trickier than it looks; I got it to work by putting the label > on the symbol table but then had to wait until the data step finished to be > able to use it, thus the proc datasets in the solution rather than just code > in the same data set for the label. > > data temp; > x='1'; > label x ='another label'; > run; > > data temp2; > set temp; > y=input(x,1.); > call symput('label_x',vlabel(x)); > run; > > proc datasets library=work nolist; > modify temp2; > label y="&label_x"; > quit; > > > -Mary > > --- Rajat.Mathur@DIAMONDCONSULTANTS.COM wrote: > > From: "Mathur, Rajat" <Rajat.Mathur@DIAMONDCONSULTANTS.COM> > To: SAS-L@LISTSERV.UGA.EDU > Subject: Query around label > Date: Wed, 15 Jul 2009 12:51:00 -0500 > > Hi > > Here is my problem around labels: > > data x.temp; > x='1'; > label x ='some label'; > run; > > data x.temp2; > set x.temp; > y=input(x,1.); > run; > > Now I need the same label for y as it is for x. > > Can anyone help me with this? > > Thanks in advance > -Rajat > > ________________________________ > This transmission may (i) be subject to contractual, statutory or other > obligations of confidentiality; (ii) contain "protected health information " > as defined in HIPAA or "non-public personal information " as defined under > data privacy laws; or (iii) be otherwise strictly confidential. If you are > not the intended recipient of this message, you may not disclose, print, > copy or disseminate this information. If you have received this in error, > please reply to the sender only and delete the message. Unauthorized > interception of this e-mail is a violation of federal law. Diamond's > operating subsidiary in North America is Diamond Management & Technology > Consultants NA, Inc.; in the U.K. and Europe, Diamond Management & > Technology Consultants Limited; and in Asia, Diamond Management & Technology > Consultants Pvt. Ltd. >


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