2011-06-14 108 views
1

我写了简单的更新/插入语句,返回语法错误,我错过了什么?表名是笔记,字段备注是类型备忘录,acaps是双重备注。我的更新和插入语句的SQL语法错误

update notes set note='why is there a syntax error' where acaps=12345 
在我的INSERT语句

语法错误太多:

insert into notes (acaps,note,updated,userId) values (12345,'Why is there a syntax error',#6/13/2011 5:07:35 PM#,'BRSANDE') 

回答

2

您正试图使用​​保留字:List of reserved words in Access 2002 and in later versions of Access

update [notes] 
set [note] = 'why is there a syntax error' 
where [acaps] = 12345 


insert into [notes] ([acaps], [note], [updated], [userId]) 
values (12345, 'Why is there a syntax error', #6/13/2011 5:07:35 PM#, 'BRSANDE') 
+0

好,我真的需要研究这些保留的关键字,我绊倒再起。谢谢! – DontFretBrett 2011-06-14 05:00:44