first_page the funky knowledge base
personal notes from way, _way_ back and maybe today

T-SQL: DELETEing Rows Based on a Date Column; Use of DATEADD() And GETDATE()

The following t-SQL deletes rows from a table named "output_wal_ytm_detail" where its column calc_date contains values over 10 days old:

DELETE output_wal_ytm_detail
WHERE calc_date < DATEADD( dd , -10 , GETDATE() )
mod date: 1999-02-09T19:35:25.000Z