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 (February 2004, week 3)Back to main SAS-L pageJoin or leave SAS-L (or change settings)ReplyPost a new messageSearchProportional fontNon-proportional font
Date:         Wed, 18 Feb 2004 14:46:52 +0530
Reply-To:     Arunk@DELHI.TCS.CO.IN
Sender:       "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From:         Arun X Kumar <Arunk@DELHI.TCS.CO.IN>
Subject:      Re: Resolving Macro variable in Cards Stmt!
Comments: To: Easwara Moorthy <easwar_ps@YAHOO.COM>
Content-Type: text/plain; charset="us-ascii"

Easwar, Cards or datalines are not used inside a macro. See if the logic below solves your problem.....

%let a=Year;

%macro eas; Data one; empid="&a.2004";output; empid="&a.2003";output; empid="&a.2002";output; ; run;

%mend;

%eas;

Thanks and Regards Arun Kumar

Easwara Moorthy <easwar_ps@YAHOO.COM> Sent by: "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU> 02/18/2004 01:31 PM Please respond to Easwara Moorthy

To: SAS-L@LISTSERV.UGA.EDU cc: Subject: Resolving Macro variable in Cards Stmt!

Hi All... I need to resolve a Macro variable in a Data step.How can i do that!? I'll be Happy if i get a solution!

Requirement -----------

%let a='Year'; ........ ........ ........

%macro eas; Data one; input empid; datalines; &a2004 &a2003 &a2002 ; run; %mend;

%eas;

expected result: ---------------- Year2004 Year2003 Year2002

Thanks in Aadvance!

Easwar!


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