+ -
当前位置:首页 → 问答吧 → 在sql查询分析器执行update无效?

在sql查询分析器执行update无效?

时间:2011-12-13

来源:互联网

最近不知什么原因,在sql查询分析器执行update无效,delete都可以,是哪里设定了?
很郁闷,路过的帮看看。

作者: huiemily   发布时间: 2011-12-13

语句写错了吧

作者: Beirut   发布时间: 2011-12-13

晕,不是写错了,不至于这么低级的问题会到这里来问啊,select都没有问题的,有记录的。

作者: huiemily   发布时间: 2011-12-13

重新启动一下服务试试。

作者: fredrickhu   发布时间: 2011-12-13

引用 2 楼 huiemily 的回复:

晕,不是写错了,不至于这么低级的问题会到这里来问啊,select都没有问题的,有记录的。

你是怎么写的

SQL code
--> 测试数据:[table1]
if object_id('[table1]') is not null drop table [table1]
create table [table1]([user] int,[sorce] int)
insert [table1]
select 1,10 union all
select 2,10 union all
select 3,10

update [table1] set [sorce]=[sorce]*[user]

select *from [table1]

drop table [table1]


试试,这样都无效吗?那还真没见过

作者: Beirut   发布时间: 2011-12-13

执行update 有什么提示没有? 
有没有受影响行数的提示?

作者: Beirut   发布时间: 2011-12-13