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...

how to update a null value field in sql server

eg
a table contains 3 fields id,name,salary
and 3 records
salary of 1 record is null
i want update the nullfield

111 arun 300
112 ddd 200
113 ttt null
i want to update table with add 100 to every record include null
after updation
the recrds should be
111 arun 400
112 ddd 300
113 ttt 100

Answer Posted / mohan

update #temp
set sal = COALESCE(sal+100,100)

Is This Answer Correct ?    4 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Is mysql the same as sql server?

1031


How do I install only the client tools of sql server 2000?

1122


What is a livelock?

1011


Explain the flow of creating a cube? : sql server analysis services, ssas

1098


How do I view a stored procedure in sql server?

1030


How can you ensure that the database and sql server based application perform well?

1118


What were the latest updates to SQL Azure service?

113


How to return the date part only from a sql server datetime datatype?

1161


What is precedence constraint?

1033


What are the different type of replication in sql server?

1013


What are types of scd? : sql server analysis services, ssas

1077


How to use go command in "sqlcmd"?

1261


What is inline variable assignment?

1079


How to change the system date and time from SQL Plus Terminal ?

1268


How column data types are determined in a view?

1005