Automatically Delete Record from table
i want that record automatically delete from table after 24 hours in c# (using linq to sql)
Know the answer? Post it — somebody with the same question will find it here.
Sign in to answer this question
It is the same account you read, post and publish with — and you will come straight back to this page.
Jignesh TrivediPosted Jan 19, 2015, 11:48 PM
Hi,
To achieve this you have to create console application which is run one time per day that delete your old record from table. else you can use SQL JOB to perform the same operation.
A job is a specified series of operations performed sequentially by SQL Server Agent. A job can perform a wide range of activities, including running Transact-SQL scripts, command prompt applications, Microsoft ActiveX scripts, Integration Services packages, Analysis Services commands and queries, or Replication tasks. Jobs can run repetitive or schedulable tasks, and they can automatically notify users of job status by generating alerts, thereby greatly simplifying SQL Server administration.
Please refer for SQL job...
http://msdn.microsoft.com/en-us/library/ms186273.aspx
hope this will help you.