Here is a great tip from SCONSIG. link
/******************************************************************/
/***TIP00039.SAS ***/
/*** Leap Year Problem ***/
/*** ***/
/*** Most of us know that if the year is divisible by 4 then ***/
/*** that year is a Leap Year. However, if the year is a ***/
/*** century year and is NOT divisible by 400 then that ***/
/*** century year is NOT A LEAP YEAR. ***/
/*** (ie, 1700, 1800, 1900, 2100, 2200, 2300 are not LEAP ***/
/*** YEARS) ***/
/*** ***/
/******************************************************************/
data leapyear;
do year = 1600 to 2400 by 100;
date = mdy(02,29,year); /*** Leap Date ***/
if date = . then do; /*** If FEB 29th but not a Leap Year ***/
date = mdy(03,01,year) - 1; /*** Make date March 1st and then ***/
end; /*** subtract 1 day ***/
output;
end;
format date mmddyy10.;
run;
proc print; run;
/*** end of sas program - TIP00039 ***/
It is possible to incorporate this into your load in one way or the other.