我不知道为什么我会收到这个错误.这可能是我在语法中看不到的,所以任何帮助都会非常感激.
声明
INSERT INTO pwd_review (id, request_date, being_reviewed, review_explain,
attached_docs, doc_explain, age_met, age_explain,
years_met, years_explain, severity, severity_explain,
restriction, restriction_explain, require, require_explain)
VALUES(410, DATE '2009-12-10', 0, NULL, 0, NULL, 0, NULL, 0, NULL, 0,
'Dr M Beaulieu has provided further information indicating that applicant is severly ill and disabled. Applican''t condition is confirmed as rectal adenocarcinoma, she has endured dhemo and readiation therapy and is under care of the Oncology Team, surgeon and GP.', 0,
'Information from Dr states that applicant is unable to sit, has great difficulty walking and requires ongoing support from the Community Support Services',
0, NULL);
Run Code Online (Sandbox Code Playgroud)
错误
1064 - 您的SQL语法出错; 检查手册
对应于您的MySQL服务器版本,以便在'require,require_explain)附近使用正确的语法VALUES(410,DATE'2009-12-10',0,NULL,0,NULL,0,NULL,0,NUL'在行1
谢谢.
REQUIRE是一个保留的MySQL关键字.您必须将其括在反引号中:
`require`
Run Code Online (Sandbox Code Playgroud)
此外,值得指出的是,MySQL使用反斜杠转义单引号,而不是SQL Server和Access等两个单引号.如果以上是您的确切SQL语句并且单引号未被转义,则此短语可能会成为问题:
Applican''t condition
Run Code Online (Sandbox Code Playgroud)