#1064,xampp,phpMyAdmin,MYSQL - 为什么 mySQL 语法有错误?
#1064, xammp, phpMyAdmin, MYSQL - Why have I an error in mySQL syntax?
#1064 - You have an error in your SQL syntax; check the manual that corresponds to your
MariaDB server version for the right syntax to use near ') VIRTUAL,
`title_type` VARCHAR(45) NULL DEFAULT null,
PRIMARY KEY (`id`))' at line 2
这是脚本的一部分:
CREATE TABLE IF NOT EXISTS `sggis`.`maps_type` (
`id` INT GENERATED ALWAYS AS () VIRTUAL,
`title_type` VARCHAR(45) NULL DEFAULT 'yandex',
PRIMARY KEY (`id`))
ENGINE = InnoDB;
SQL 说问题出在第二行,但我找不到。
MySQL Workbench.
生成的代码
使用 VIRTUAL 列时,您需要指定表达式
Any legal, deterministic expression which can be calculated is
permitted, with the following exceptions:
你的表情是空白的
#1064 - You have an error in your SQL syntax; check the manual that corresponds to your
MariaDB server version for the right syntax to use near ') VIRTUAL,
`title_type` VARCHAR(45) NULL DEFAULT null,
PRIMARY KEY (`id`))' at line 2
这是脚本的一部分:
CREATE TABLE IF NOT EXISTS `sggis`.`maps_type` (
`id` INT GENERATED ALWAYS AS () VIRTUAL,
`title_type` VARCHAR(45) NULL DEFAULT 'yandex',
PRIMARY KEY (`id`))
ENGINE = InnoDB;
SQL 说问题出在第二行,但我找不到。 MySQL Workbench.
生成的代码使用 VIRTUAL 列时,您需要指定表达式
Any legal, deterministic expression which can be calculated is permitted, with the following exceptions:
你的表情是空白的