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 |
Ali.M.Habib
Yak Posting Veteran
54 Posts |
Posted - 2009-08-19 : 02:31:42
|
I get the following error when executing the code listed below. Any ideas what I'm doing wrong?Server: Msg 16947, Level 10, State 1, Line 1093055397No rows were updated or deleted.The statement has been terminated.(0 row(s) affected)declare @d1 char(1)declare cur1 cursor for select col1 from tab1 where col2 = 1open cur1fetch next from cur1 into @d1update tab1 set col1 = '1' where current of cur1deallocate cur1any help please |
|
madhivanan
Premature Yak Congratulator
22864 Posts |
Posted - 2009-08-19 : 04:00:26
|
What are you trying to do?Wont this work simply?update tab1 set col1 = '1' where col2=1MadhivananFailing to plan is Planning to fail |
|
|
|
|
|