View Single Post
  #50  
Old 02-10-2011, 09:42 AM
dumples dumples is offline
Member
CAS
 
Join Date: Sep 2003
Posts: 1,247
Default

Quote:
Originally Posted by ThatGuy View Post
Any thoughts on why my If else statement isn't working?

%if ((&mth=9 and &year=2009) or (&year=2009 and &mth=12) or (&year>2009)) %then/* SET LOCATION OF INPUT AND OUTPUT FILES */
%do;
%let yearabr = %sysfunc(substr(&year,3,2));
%If &mth <10 %then
%let al_ext=AL&yearabr.0&mth..vmf;
%else
%let al_ext=AL&yearabr&mth..vmf;

%let hmDIR=E:\***;
%If &mth <10 %then
%let hmVMF=E:\***\&year.0&mth-Stream\VMFs;
%else
%let hmVMF=E:\***\&year&mth-Stream\VMFs;
%end;
%else/* SET LOCATION OF INPUT AND OUTPUT FILES */
%do;
%let yearabr = %sysfunc(substr(&year,3,2));
%If &mth <10 %then
%let al_ext=AL&yearabr.0&mth..vmf;
%else
%let al_ext=AL&yearabr&mth..vmf;

%let hmDIR=R:\***;
%If &mth <10 %then
%let hmVMF=R:\***\&year.0&mth-Stream\VMFs;
%else
%let hmVMF=R:\***\&year&mth-Stream\VMFs;
%end;
Does this do it?
Reply With Quote
 
Page generated in 0.20253 seconds with 9 queries