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 (June 2005, week 4)Back to main SAS-L pageJoin or leave SAS-L (or change settings)ReplyPost a new messageSearchProportional fontNon-proportional font
Date:         Wed, 22 Jun 2005 15:18:44 -0700
Reply-To:     "Nordlund, Dan" <NordlDJ@DSHS.WA.GOV>
Sender:       "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From:         "Nordlund, Dan" <NordlDJ@DSHS.WA.GOV>
Subject:      Re: date -  macro variable problem
Comments: To: David Fickbohm <davefickbohm@YAHOO.COM>
Content-Type: text/plain

David,

Eliminate the single quotes and move the 'D' outside the double quotes, i.e.

IF ((profiledt >= "&START_DT"D) AND (profiledt <= "&END_DT"D));

Hope this helps,

Dan

Daniel J. Nordlund Research Investigator Research and Data Analysis Washington State Department of Social and Health Services Olympia, WA 98504-5204

-----Original Message----- From: SAS(r) Discussion [mailto:SAS-L@LISTSERV.UGA.EDU] On Behalf Of David Fickbohm Sent: Wednesday, June 22, 2005 3:13 PM To: SAS-L@LISTSERV.UGA.EDU Subject: date - macro variable problem

People,

I am trying to use macro variables instead of harding coding 15jun05'd.

I am using %let start_dt = 01JUN05;

and the code below.

DATA all_profiles_FINAL;

SET ALL_PROFILES_CLEANED;

PROFILEDT = DATEPART(PROFILE_DT);

IF ((profiledt >= "&START_DT'D") AND (profiledt <= "&END_DT'D"));

RUN;

Can someone please give me an idea where to look in a manual or a book or something.

Sorry

Dave

Dave Fickbohm Use Technology to the Fullest 1250 45th st suite 200 Emeryville, CA, 94608 510 594 4151 voice __________________________________________________ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.com


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