Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

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


Please Help Members By Posting Answers For Below Questions

How to concatenate two strings in SQL Server.

1153


You have a table with close to 100 million records recently, a huge amount of this data was updated now, various queries against this table have slowed down considerably what is the quickest option to remedy the situation?

908


Can two different columns be merged into single column? Show practically?

1067


How can you find out which stored procedures are recompiling?

920


What is outer join in sql server joins?

1126


What do you understand by the data quality services in sql server?

953


How to test values returned by a subquery with the in operator?

1203


What are types of storage modes? : sql server analysis services, ssas

1048


Why functions are used in sql server?

964


What is the difference between varchar and varchar types?

1077


How many replicas are maintained for each SQL Azure database?

142


Why truncate is ddl command?

1069


What is data source view or dsv? : sql server analysis services, ssas

1007


What is data source object?

1008


How to connect sql server management studio express to sql server 2005 express?

1049