六狼论坛

 找回密码
 立即注册

QQ登录

只需一步,快速开始

新浪微博账号登陆

只需一步,快速开始

搜索
查看: 49|回复: 0

如何将mysql5的sql文件导入到mysql4?

[复制链接]

升级  75.55%

819

主题

819

主题

819

主题

探花

Rank: 6Rank: 6

积分
2511
 楼主| 发表于 2013-1-13 18:46:20 | 显示全部楼层 |阅读模式
1、将mysql5里导出的sql文件导入到mysql5中。 2、用mysqldump -uroot -p1234 --opt --compatible=mysql40 -A -re:\localhost.sql --compatible=name参数描述如下: --compatible=name Change the dump to be compatible with a given mode. By default tables are dumped in a format optimized for MySQL. Legal modes are: ansi, mysql323, mysql40, postgresql, oracle, mssql, db2, maxdb, no_key_options, no_table_options, no_field_options. One can use several modes separated by commas. Note: Requires MySQL server version 4.1.0 or higher. This option is ignored with earlier server versions. 3、将e:\localhost.sql导入mysql4,如mysql命令行中 source e:\localhost.sql
您需要登录后才可以回帖 登录 | 立即注册 新浪微博账号登陆

本版积分规则

快速回复 返回顶部 返回列表