ashok reddy

ashok reddy

  • NA
  • 10
  • 0

How to Update automatically in Data in Sql Server

Sep 27 2012 10:28 AM
I'm using Asp.Net with vb with Sql Server 2005 as Database....

in my Database Table, i'm having Emp_Time_Details Table with ID, Name, Given_Time, Status as columns... 
like
ID-----Name-----Given_Time----------------Status
1------as ----2008-10-17 16:23:15.000-------1
2------qw ----2008-10-10 17:5:15.000--------1
3------cv ----2008-10-15 11:3:15.000--------1
4------cd ----2008-10-13 05:45:15.000-------1
5------uj ----2008-10-14 03:2:15.000--------1

By default Status Column will be '1'

Here I want to CHANGE THE STATUS COLUMN AUTOMATICALLY wrt GetDate() in Sql Server 2005..

Like if Given_Time >= GetDate()... I want to change Data inside STATUS COLUMN as '0'

How to Update the Data inside Table AUTOMATICALLY wrt GetDate() in SqlServer-2005.. ie here Data inside column should Keep On checking the GetDate() value for Each & Every Second...

Thank You.. 


Answers (2)