MySQL server version for the right syntax to use near 'TYPE=MyISAM'

简介:
+关注继续查看

最近将一个版本为4.0.18-Max的MySQL数据库迁移到5.6.20- enterprise-commercial-advanced上。好吧,这是我迄今为止,见到过的最古老版本的MySQL数据库,这个数据库跑在一个 512M上老古董PC上,已经存活了十多年了。使用mysqldump导出导入时,遇到了一个错误:

mysql>CREATE TABLE BackupFrequency 
 
( BackupFrequency char(15ULL default '', PRIMARY KEY (BackupFrequency) ) TYPE=MyISAM;
 
ERROR 1064 (42000): 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 'TYPE=MyISAM' at line 1

clip_image001

查了一下资料,发现这个是由于MySQL创建表的写法 TYPE=MyISAM 太古老了,在MySQL 5.6.20上已经不支持了,这个应该在MySQL 5.1后的相关版本已经取消了支持,具体参考链接http://bugs.mysql.com/bug.php?id=17501,只能将 mysqldump导出的脚本文件里面的TYPE=MyISAM 全部替换成ENGINE=InnoDB后,才能成功导入。

相关实践学习
基于CentOS快速搭建LAMP环境
本教程介绍如何搭建LAMP环境,其中LAMP分别代表Linux、Apache、MySQL和PHP。
全面了解阿里云能为你做什么
阿里云在全球各地部署高效节能的绿色数据中心,利用清洁计算为万物互联的新世界提供源源不断的能源动力,目前开服的区域包括中国(华北、华东、华南、香港)、新加坡、美国(美东、美西)、欧洲、中东、澳大利亚、日本。目前阿里云的产品涵盖弹性计算、数据库、存储与CDN、分析与搜索、云通信、网络、管理与监控、应用服务、互联网中间件、移动服务、视频服务等。通过本课程,来了解阿里云能够为你的业务带来哪些帮助     相关的阿里云产品:云服务器ECS 云服务器 ECS(Elastic Compute Service)是一种弹性可伸缩的计算服务,助您降低 IT 成本,提升运维效率,使您更专注于核心业务创新。产品详情: https://www.aliyun.com/product/ecs
相关文章
|
29天前
|
关系型数据库 MySQL
报错:1130-host … is not allowed to connect to this MySql server,MySQL
报错:1130-host … is not allowed to connect to this MySql server,MySQL
34 0
|
2月前
|
SQL 关系型数据库 MySQL
check the manual that corresponds to your MySQL server version for the right syntax to use near lin
注意这种一般情况下是语法问题,说明mysql的各种语句还是不够熟练, (1)看表名是不是使用了Mysql的关键字,如果是,请立马改掉; (2)语句给出哪里错误,如我的题目中给出“near”,说明在那附近有问题。 (3)检查mybatis中mapper里sql语句占位符是否写对,我的问题是将#{name}写成了#(name),尴尬。
|
域名解析 关系型数据库 MySQL
mysql中出现Unit mysql.service could not be found 的解决方法
mysql中出现Unit mysql.service could not be found 的解决方法
2127 1
|
关系型数据库 MySQL
MySQL - The MySQL server is running with the --secure-file-priv option
MySQL - The MySQL server is running with the --secure-file-priv option
108 0
MySQL - The MySQL server is running with the --secure-file-priv option
|
SQL 关系型数据库 MySQL
check the manual that corresponds to your MySQL server version for the right syntax to use near
check the manual that corresponds to your MySQL server version for the right syntax to use near
573 0
check the manual that corresponds to your MySQL server version for the right syntax to use near
|
关系型数据库 MySQL 数据库
记一次mysqldump: Error 2013: Lost connection to MySQL server during query when dumping table问题
mysqldump: Error 2013: Lost connection to MySQL server during query when dumping table
1786 0
|
关系型数据库 MySQL
check the manual that corresponds to your MySQL server version for the right syntax to use near '...
背景交代 折扣价格设置的是负数,框架用的TP5。 活动规则:当活动开始时候销售价格加上折扣价格(相当于减折扣价格)就是活动价格,当活动结束时候,减去折扣价格(负负得正)就恢复原价。
6815 0
|
关系型数据库 MySQL C语言
MySQL 启动报错Table 'mysql.plugin' doesn't exis(转载)
安装完成后,按照网上说启动mysql时却报了以下错误: [root@localhost bin]# ./mysqld 2015-10-23 16:54:55 0 [Warning] TIMESTAMP with implicit DEFAULT value is deprecated.
1220 0
|
Oracle 关系型数据库 MySQL
推荐文章
更多