Calculating T-90 working days date?
Posted on 2009-05-06
I have a table which holds details of business transactions. One of the fields in the table is dt_bus which is the date the business transaction occurred. Every 40 days I move transactions older than 40 days to a TRANS_ARCH table, to archive them. However, I now want to delete all transactions where dt_bus is greater the 90 working days from TRANS_ARCH (as I can retrieve these entries from tape if ever required)
How can I easly and quickly calculate the date which is 90 working days before today (ie T - 90). I don't think it's possible to include holidays so considering Mon - Fri as the working week is fine