Microsoft
Software
Hardware
Network
Question : SQL Query to delete all records older than 365 days
I need to write a sql query to delete all records in my database older than 365 days. The date/time field name is called 'DateShipped'. TIA!
Answer : SQL Query to delete all records older than 365 days
delete from tableName
where DateShipped < dateadd( dd, -365, convert(varchar,getdate(),
112) )
Random Solutions
How do I get rid of double contacts in Outlook?
Sharepoint Server Error in '/' Application
How to create a password for access forms
How to delete a record from a form page.
How to have setup.exe install a file into sytems32\drivers?
Error: Scaling of decimal value resulted in data truncation
How to use two values in a VB.NET ComboBox
SBS 2003 hangs will setting up personalized settings for Internet Explorer after IE7 upgrade
Application has generated an exception that could not be handled
Cannot rename reports in Access 2007 runtime - bug?