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 (September 2003, week 1)Back to main SAS-L pageJoin or leave SAS-L (or change settings)ReplyPost a new messageSearchProportional fontNon-proportional font
Date:   Wed, 3 Sep 2003 20:14:04 +0100
Reply-To:   ma015 b8234 <ma015b8234@BLUEYONDER.CO.UK>
Sender:   "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From:   ma015 b8234 <ma015b8234@BLUEYONDER.CO.UK>
Subject:   Macrovariable not resolving in Intnx function
In-Reply-To:   <9B501B3774931C469BCCCC021BE537223D4A09@remailnt2-re01.westat.com>
Content-Type:   text/plain; charset="iso-8859-1"

Dear SAS-L Contributors:

I am trying to get the last month from today's date and export it to Excel. But I get an error because the macro variable does not resolve within the intnx function.

Any suggestions for getting around this?

Thanks in advance for your help.

John

filename otherway dde 'Excel|D:\DQ\Reports\[Monthly_Report.xls]Data!R2C3:R2C3';

data _null_; file otherway; %let date=date(); a=intnx('month',"&date"d,-1); put a; run;

219 a=intnx('month',"&date"d,-1); -------- 77 ERROR: Invalid date/time/datetime constant "&date"d. ERROR 180-322: Statement is not valid or it is used out of proper order.

ERROR 77-185: Invalid number conversion on "&date"d.


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