i have 4 tables.. T1, T2, T3, T4..
these tables have the same structure and they store the
information entered in different years..
T1 stored 2002, T2 stored 2003, T3 stored 2004 and T4 stored
2005..
i want to copy contents in T1 to T2, T2 to T3, T3 to T4 and
T4 to T1..
how do i do that? Temp tables cannot be used..
Answer Posted / madhu sudhan g
Hiii
DELETE T1
OUTPUT DELETED.COLUMN1,DELETED.COLUMN2...
INTO T2
DELETE T2
OUTPUT DELETED.COLUMN1,DELETED.COLUMN2...
INTO T3
DELETE T3
OUTPUT DELETED.COLUMN1,DELETED.COLUMN2...
INTO T4
Is This Answer Correct ? | 1 Yes | 0 No |
Post New Answer View All Answers
How do I create a stored procedure in dbml?
what are cursors? : Sql server database administration
What happens when converting big values to integers?
What is a result set object returned by odbc_exec()?
How to modify an existing stored procedure in ms sql server?
How to store and query spatial data?
What is xdr?
You notice that the transaction log on one of your databases is over 4gb the size of the data file is 2mb what could cause this situation, and how can you fix it?
What is the use of commit?
What is the difference between varchar and varchar types?
What are the types of user defined functions in sql server?
What are the basic functions for master, msdb, model, tempdb databases?
How to optimize stored procedure optimization?
How do indexes help, types?
How to add the custom code in Report?