开发者

Sql delete not appearing to work

开发者 https://www.devze.com 2023-03-11 15:18 出处:网络
I am running delete sql in Managment Studio 2008 and it indicated to me the sql has worked....but it hasnt.

I am running delete sql in Managment Studio 2008 and it indicated to me the sql has worked....but it hasnt.

For example

select count(*) from MyTable where  [MYkey] =24  

returns 1

delete from MyTable where  [MYkey] =  24

Rows Affected 1

But if I immediately run the first statement again, the record is 开发者_开发问答still there. If I try an update statement, that works. I am seeing this behaviour on all tables in the database.

I had a few issues with the Transaction log being full a few days ago, I change the recovery model to simple. Could this be related? If so what do I need to do?


Try this -

  BEGIN TRANSACTION;
  delete from MyTable where  [MYkey] =  24;
  COMMIT TRANSACTION;
0

精彩评论

暂无评论...
验证码 换一张
取 消