Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

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 / krishna reddy l

update example set column1 = case when column1=0 then 1
when column1=1 then 0 end

Is This Answer Correct ?    0 Yes 3 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How many types of dimensions are there and what are they? : sql server analysis services, ssas

1118


Describe how to use linked server?

1072


Explain log shipping?

1074


What do you mean by cardinality?

938


What is nolock hint in sql server 2008

1178


what is a mixed extent? : Sql server administration

1169


Explain about unique identifier data type in sql server?

969


What are clustered and non-clustered index?

1049


What is an active database?

1065


How is a full-text index updated?

998


What are the general features of sql server management studio? : sql server management studio

1126


What is sql server used for?

1093


How to add code to the existing article (using improve article)?

1162


What are .mdf files?

1012


Can a table be moved to different filegroup?

1023