gpt4 book ai didi

mysql - INSERT INTO 语法错误 SQL

转载 作者:行者123 更新时间:2023-11-29 03:53:08 26 4
gpt4 key购买 nike

我不知道为什么会收到此错误。这可能是我在语法中看不到的东西,因此我们将不胜感激任何帮助。

声明

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);

错误

1064 - You have an error in your SQL syntax; check the manual

that corresponds to your MySQL server version for the right syntax touse near 'require,require_explain) VALUES(410,DATE'2009-12-10',0,NULL,0,NULL,0,NULL,0,NUL' at line 1

谢谢。

最佳答案

REQUIRE 是一个 reserved MySQL keyword .您必须将其括在反引号中,如下所示:

`require`

此外,值得指出的是,MySQL 使用反斜杠转义单引号,而不是像 SQL Server 和 Access 这样的两个单引号。如果以上是您的确切 SQL 语句并且该单引号未被转义,则此短语可能会出现问题:

Applican''t condition

关于mysql - INSERT INTO 语法错误 SQL,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/7084476/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com