If I have a table T with 4 rows & 2 columns A & B. A has
values 1,2,3,4. and B has 10,20,30,40. Write an Update SQL
query which can Swap the values of A & B for all records.
(Do not use a sub-query)
Answer Posted / avi007
select A as "B",B AS "A" from T;
Is This Answer Correct ? | 1 Yes | 2 No |
Post New Answer View All Answers
What are the different types of joins in sql?
how to delete duplicate rows from a join tables(I have three tables on that join) how do you know which join is need to be used? The select statement I have is: SELECT gc_skill_type.skill_type, gc_area_tec.area, gc_technology.technology, gc_technology.id_technology, gc_area_tec.id_area_tec FROM gc_skill_type, gc_area_tec, gc_technology WHERE gc_area_tec.id_skill_type (+) = gc_skill_type.id_skill_type AND gc_technology.id_area_tec (+) = gc_area_tec.id_area_tec order by gc_skill_type.skill_type asc, gc_area_tec.area asc, gc_technology.technology asc
What is cross join example?
What is sequence in sql?
What is an inconsistent dependency?
What will you get by the cursor attribute sql%notfound?
What is sql keyword?
Why use triggers in sql?
How are sql commands classified?
What are basic techniques of indexing?
what is cursor. write example of it. What are the attributes of cursor.
How do I delete a trigger?
What are conditional predicates?
What is pl sql script?
How exception is different from error?