Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Wanet Telecoms Ltd on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Archiving Data

Status
Not open for further replies.

shaminda

Programmer
Jun 9, 2000
170
US
I have a database that have 4 tables. In one of the tables a field starts from 000 and keep on incrementing daily till reaches 999. After 999 it starts all over starting at 000.

When it reaches 999 I want to move the data(all 4 tables) from 000 to 999 to a new database. This proccess occurs every 4 months. I know how to move the data manualy. But how do I let SQL Server do it for me without my interaction?
 
Seems like you could use an Insert trigger on the table, and when you find the value of Inserted.CounterColumn is 999, issue the commands that select into the new database, or kicks off a DTS job.

Robert Bradley

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top