Site Sponsored By: SQLDSC - SQL Server Desired State Configuration
Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
HiI hope you all will be able to help me...I have a Time table pp(date/time) 9/30/2006I want to run a sproc against this so that every year on this date it will increase this date to 9/30/2007 then the next year to 9/30/2008 etc....Any easy way to do this?Thanks for your helpP
DonAtWork
Master Smack Fu Yak Hacker
2167 Posts
Posted - 2006-10-18 : 14:41:54
this simply sounds like poor design. WHY would you want to do this?[Signature]For fast help, follow this link:http://weblogs.sqlteam.com/brettk/archive/2005/05/25.aspxLearn SQLhttp://www.sql-tutorial.net/ http://www.firstsql.com/tutor.htm http://www.w3schools.com/sql/default.asp
snSQL
Master Smack Fu Yak Hacker
1837 Posts
Posted - 2006-10-18 : 14:43:42
I'm not sure from your description exactly which rows you want to update - this will add one year to the column for all rows that have the date equal to todays date.