Consider a table with 8 rows 4 rows contains value 0 and 4
rows contains value 1.Now write a single update query to make
all 0's as 1 and all 1's as 0
Answer Posted / vicky
Update test01 Set num =(case num when 1 then 0 when 0
then 1 else 3 end)
| Is This Answer Correct ? | 10 Yes | 2 No |
Post New Answer View All Answers
Types of Authentications in Sql Server? How user gets authenticated through windows authentication?
Explain primary key, foreign key and unique key?
What does dml stand for?
Thanks to some maintenance being done, the sql server on a failover cluster needs to be brought down. How do you bring the sql server down?
What is log shipping?
How to access the deleted record of an event?
What will be the value of @@fetch_status if a row that was a part of the cursor resultset has been deleted from the database after the time the stored procedure that opened the cursor was executed?
What is the data tier application?
Is sql different from sql server?
What is delete query?
What is query processing?
1.how to find the dead lock in sql server? 2.How to fine the memory leaks in sql server? 3.suppose transaction log file increasing what action will take ?
Where are sql server usernames and passwords stored in the sql server?
What is the difference between the 2 operating modes of database mirroring?
What are a scheduled jobs or what is a scheduled tasks?