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 / siva
insert into T1
select *from t2
union/union all (without duplicates/with duplicates )
select *from t3
union/union all
select *from t4
.
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
What is the difference between Clustered and Non-Clustered Index?
what is an index? : Sql server database administration
How to create view in stored procedure sql server?
In one interview...interviewer ask me question pleas tell me sql server architecture.. can any body tell me the sql server architecture with digram
What is the use of custom fields in report?
why does a sql statement work correctly outside of a user-defined function, but incorrectly inside it? : Sql server administration
Ways to improve the performance of a SQL Azure Database?
How to delete a database in ms sql server?
What are ddl (data definition language) statements for tables in ms sql server?
Which trace flags are enabled in sql server?
how do you test proper tcp/ip configuration windows machine? : Sql server database administration
How you can add messages to the nt event log from within a stored procedure?
What is outer join in sql server joins?
What is 3nf normalization form?
Where can you find the error log information? : sql server database administration