更新和删除查询不起作用 [英] Update and Delete queries do not work
本文介绍了更新和删除查询不起作用的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
你好,
我是VB.NET的新手.我有一个MS Access数据库,并且我的Update和Delete查询无法正常运行.
这些是我现在有的查询.
更新
Hello,
I am new to VB.NET. I have an MS Access database and my Update and Delete queries do not work as I expect them to.
These are the queries I have now.
Update
Update Emp Set name="Project" Where no = 2;
删除
Delete
Delete From Emp Where no=1;
请帮我.我知道这是VB.NET/Access中非常基本的内容,但我不知道下一步该怎么做.
Please help me. I know this is very basic stuff in VB.NET/Access but I don''t know what to do next.
推荐答案
你好,
尝试使用[no]代替 no .否是ODBC保留关键字
更新Emp Set名称="Project",其中[no] = 2;
http://msdn.microsoft.com/en-us/library/aa238507% 28SQL.80%29.aspx [ ^ ]
hello,
Try [no] instead of no. no is ODBC reserved keywords
Update Emp Set name=''Project'' Where [no] = 2;
http://msdn.microsoft.com/en-us/library/aa238507%28SQL.80%29.aspx[^]
希望此 [ ^ ]可能会帮助您.
Hope this[^] might hep you.
我不确定,但请使用单引号,例如
I am not sure but use single quote like
Update Emp Set name='Project' Where no = 2;
这篇关于更新和删除查询不起作用的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文