MySql 错误 1064 - 使用 MySQL WorkBench 创建
我使用 MySQL WorkBench 创建了这个
CREATE TABLE IF NOT EXISTS `bakasura_new`.`cities` (
`id` INT(11) UNSIGNED NOT NULL AUTO_INCREMENT ,
`name` VARCHAR(255) NOT NULL COMMENT 'City Name' ,
`short_name` VARCHAR(255) NOT NULL COMMENT 'Short Name' ,
`country_id` INT(11) UNSIGNED NOT NULL ,
PRIMARY KEY (`id`) ,
INDEX `fk_cities_countries` (`country_id` ASC) ,
ENGINE = InnoDB;
我收到此错误
MySQL 说:文档
#1064 - 您的 SQL 语法有错误;检查手册
对应于你的MySQL服务器 正确使用语法的版本 第 8 行 '= InnoDB' 附近
I created this using MySQL WorkBench
CREATE TABLE IF NOT EXISTS `bakasura_new`.`cities` (
`id` INT(11) UNSIGNED NOT NULL AUTO_INCREMENT ,
`name` VARCHAR(255) NOT NULL COMMENT 'City Name' ,
`short_name` VARCHAR(255) NOT NULL COMMENT 'Short Name' ,
`country_id` INT(11) UNSIGNED NOT NULL ,
PRIMARY KEY (`id`) ,
INDEX `fk_cities_countries` (`country_id` ASC) ,
ENGINE = InnoDB;
I am getting this error
MySQL said: Documentation
#1064 - You have an error in your SQL syntax; check the manual that
corresponds to your MySQL server
version for the right syntax to use
near '= InnoDB' at line 8
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
这里有一个悬空逗号:
最后还缺少一个括号:
You have a dangling comma here:
And you also have a missing parenthesis at the end:
最后一个
)
末尾缺少一个)
There is a
)
missing at the end of the last)