happysmile
happysmile

Reputation: 7777

update Query for a table in sql server 2005

i have an table called employees

empID name   startdate       Middate      DEptID
1     kumar  2011-04-30      2005-09-13    1
2     kiran  2011-05-23      2006-08-13    1
3     kishor 2008-04-13      2009-04-23    6
4     anu    2009-09-03      2000-06-13    1
5     priya  2010-05-04      2010-04-13    6
6     sweth  2011-07-13      2007-12-16    1
7     manu   2011-08-15      2006-12-07    6

Is there any way i can update this table so that startdate = Middate for all the employees

empID name   startdate       Middate      DEptID
1     kumar  2005-09-13      2005-09-13    1
2     kiran  2006-08-13      2006-08-13    1
3     kishor 2009-04-23      2009-04-23    6
4     anu    2000-06-13      2000-06-13    1
5     priya  2010-04-13      2010-04-13    6
6     sweth  2007-12-16      2007-12-16    1
7     manu   2006-12-07      2006-12-07    6

pls let me know how can i solve this

thanks
prince

Upvotes: 0

Views: 692

Answers (1)

Blorgbeard
Blorgbeard

Reputation: 103467

update employees set startdate=middate

Upvotes: 6

Related Questions