It doesn't work because those are SQL functions, not SAS functions. Find the relevant SAS functions. A SAS datetime is defined as the number of seconds from January 1, 1960. So exactly how your variable is stored is important. Some functions to consider: intnx intck input put datepart month/year/day timepart
... View more