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...

How to swap the data of two columns in a table. both the
columns containing varchar values.

Answer Posted / ami tkumar

Sorry for previous answer.

DECLARE @temp AS varchar(50)
UPDATE swapdata SET @temp=value2,value2=value1,value1=@temp

Is This Answer Correct ?    5 Yes 3 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

what is a sub-report?

137


Explain contrast amongst grouped and non-bunched records?

979


what stored procedure can you use to display the current processes? : Sql server administration

975


what is checksum in sql server.........???

1646


Explain where clause?

942


What is bcp? When does it used?

944


How do you set a trace flag in sql server?

1009


How to generate create table script on an existing table in ms sql server?

1115


What is SubQuery in SQL Server 2008

982


What command do we use to rename a database?

1031


What are three major types of constraints?

1063


What is a non clustered primary key?

891


Explain the difference between primary keys and foreign keys?

965


How to defragment indexes with alter index ... Reorganize?

1039


What are the types of database schema? : sql server analysis services, ssas

1086