@PaigeMiller wrote:
You can try
five_mo_ago = intnx('day',today(), -5);
Other than that, I'm afraid I don't understand your problem. Do you mean you want to delete records where variable DATE is greater than 5 days old? Or do you mean something else?
Please don't ever say "but It is not working" and provide no other information. We can't help you if you provide no other information. Please do show us the LOG for the code that isn't working (all of it, 100%, the code as it appears in the LOG, the ERRORs, WARNINGs, NOTEs, in the sequence it appears in the log, with nothing chopped out).
I did not pasted because was not able to code much on this but still I am keeping my code below. :
data final;
set housekeeping_data;
five_days_ago = intnx('day',today(), -5);
if date < Today() then delete /* HERE want that the observations which are 5 days old from my Today()
should be deleted/removed*/;
drop five_days_Ago;
proc print;
run;
Yes, Do you mean you want to delete records where variable DATE is gt than 5 days old from today.
... View more