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
Is oracle faster than sql server?
How to insert stored procedure result into temporary table?
What is use of except clause? How does it differ from not in clause?
Define clusters?
What are sql server functions?
What are scheduled tasks in sql server?
Explain the purpose of indexes?
What does null mean?
How does SSIS(Sql Server Integration Services) deffer from DTS(Data Transformation Services)?
you want to be sure that queries in a database always execute at the maximum possible speed. To achieve this goal you have created various indexes on tables which other statement will keep the database in good condition? : Sql server administration
How to get all stored procedures in sql server?
What can be used instead of trigger?
What is 2nf example?
what are questions asked in TCS for database tester (sqlserver)for 2-3 exp?
Explain sql server service broker?