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
Write a program using SQL queries to find a unique entry in a table.
What is model database? : SQL Server Architecture
Tell me what is difference between view and materialized view?
Can group by be used without aggregate functions?
What is the difference between a function and a stored procedure?
How to disable a login name in ms sql server?
what are defaults? Is there a column to which a default can't be bound? : Sql server database administration
What is the usage of sign function?
ow to bring suspect mode datbase online from scratch
Can you leave a union at any time?
What are the different editions available in sql server 2000?
What is field with example?
What is sqlcmd?
How to get a list of columns in a view using the "sp_columns" stored procedure?
Difference between aggregate functions of sql?