In the precode of my Extract transformation, I need to establish a macro variable that designates Tuesday last week, relative to the date the job is run. If I run it today, it should appear like this: 09OCT12:00:00:00. I'm almost there, but need help with a detail. This is my current code: %let last_tuesday = %sysfunc(intnx(week, %sysfunc(today()),-1,b), date9.):00:00:00; Logically enough, it sets the date to 07OCT12:00:00:00. Next I need to add two days to it, to make it Tuesday(3) instead of Sunday(1). However, no matter where I try to insert "+2", it seems to fail. Can someone please advise me how I can edit the above code to make it add two days? P.S. I've tried using week1.3 and week.3 in the above code, but those only select the Tuesday of the first week of the month no matter when the job is run (02OCT2012:00:00:00 if I run it now). Thanks.
... View more