概述
代码、错误提示如下:CREATETABLE`book`.`user`(`id`INTEGERUNSIGNEDNOTNULLAUTO_INCREMENT,`uid`VARCHAR(20)NOTNULL,`password`VARCHAR(30)NOTNULL,`realName`VARCHAR(20)NOTNULL,`g...
代码、错误提示如下:
CREATE TABLE `book`.`user` (
`id` INTEGER UNSIGNED NOT NULL AUTO_INCREMENT,
`uid` VARCHAR(20) NOT NULL,
`password` VARCHAR(30) NOT NULL,
`realName` VARCHAR(20) NOT NULL,
`gender` TINYINT(1)) UNSIGNED NOT NULL DEFAULT 0,
`email` VARCHAR(50) NOT NULL,
`tel` VARCHAR(15) DEFAULT NULL,
`question` VARCHAR(50) DEFAULT NULL,
`validateCode` VARCHAR(20) NOT NULL,
`answer` VARCHAR(50) NOT NULL,
`loginNum` INTEGER UNSIGNED NOT NULL DEFAULT 0,
PRIMARY KEY (`id`)
)
ENGINE = InnoDB
CHARACTER SET utf8 COLLATE utf8_general_ci
COMMENT = 'InnoDB free:11264 kB';
Error: 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 ‘UNSIGNED NOT NULL DEFAULT 0,
email VARCHAR(50) NOT NULL
tel VARCHAR(15)' at line 6
展开
最后
以上就是犹豫宝马为你收集整理的mysql建外键时出现1064_我用mysql建表时出现了1064号错误的全部内容,希望文章能够帮你解决mysql建外键时出现1064_我用mysql建表时出现了1064号错误所遇到的程序开发问题。
如果觉得靠谱客网站的内容还不错,欢迎将靠谱客网站推荐给程序员好友。
发表评论 取消回复