How to swap the data of two columns in a table. both the
columns containing varchar values.
Answer Posted / sandeep rana
create table tmp_t
(
aa varchar2(50),
bb varchar2(50)
)
--insert into tmp_t values('1','5')
select * from tmp_t
update tmp_t set aa=bb , bb=aa
| Is This Answer Correct ? | 7 Yes | 12 No |
Post New Answer View All Answers
How to delete duplicate rows from table except one?
Is truncate autocommit?
Difference between Logical Page and Physical Page in SSRS.
What is a filestream?
Why is normalisation important?
How to fine-tune reports?
Explain indexed views and partitioned view with their syntax.
List the data types available in mssql?
Explain what are the basic functions for master, msdb, model, tempdb databases?
How can you transfer data from a text file to a database table? Or how can you export data from a table to a comma delimited (csv) file? Or how can you import data from ms access to a table in a database? Or how can you export data from a table to an excel file?
What is exporting and importing utility?
how to create a scrollable cursor with the scroll option? : Sql server database administration
how to use DTS package in 2000,2005,2008 in sql server
Is resultset an interface?
What is tcl in sql server?