Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
Author |
Topic |
abhit_kumar
Posting Yak Master
147 Posts |
Posted - 2011-01-07 : 03:46:48
|
Dear ALL,I have a table in which there is one column named "Address1"Now in this column all the data in this displaying as follow:-sector-2, Guj,676Sector-4,AHD,8989Now i want to modify all the data in this column, if there is any "," comma found in the data, it should delete that comma from the data?How to do it?Please guide.Regards, |
|
khtan
In (Som, Ni, Yak)
17689 Posts |
Posted - 2011-01-07 : 03:58:25
|
use the replace() function to remove any commaupdate atableset address1 = replace(address1, ',', '') KH[spoiler]Time is always against us[/spoiler] |
 |
|
pk_bohra
Master Smack Fu Yak Hacker
1182 Posts |
Posted - 2011-01-07 : 03:58:34
|
If you want to remove permanently then you can update it.Update yourtable Set Address1 = Replace(Address1,',','')If you want to show but not update thenSelect Replace(Address1,',','') as Address1 from yourtable |
 |
|
|
|
|
|
|