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 |
|
kkiranvr
Yak Posting Veteran
54 Posts |
Posted - 2007-11-26 : 17:54:34
|
| We have a table and it is having records with for example “Chase“, now we don’t want those “ “ and we want just Chase instead, so how can we update the records? Is there any other easy way to do than cursor? Here I have got code for Cursor, but I am not getting the logic what to keep. And the code is heredeclare @tbl varchar(200)declare cur cursor for select name from sysobjects where type='U' and name like 'NS%'open curfetch next from cur into @tblwhile @@FETCH_STATUS = 0beginprint @tbl--exec sp_spaceused @tblfetch next from cur into @tblendclose curdeallocate curCan you please send me the logic?It will be more appreciable.-Thanks N Regards,Kanthi. |
|
|
rmiao
Master Smack Fu Yak Hacker
7266 Posts |
Posted - 2007-11-27 : 02:05:13
|
| Don't need cursor, try with replace function. |
 |
|
|
|
|
|