Copying MySQL Database to another machine(将 MySQL 数据库复制到另一台机器)
问题描述
我在 mt Windows 计算机上有一个 MySQL 数据库.我需要获取一个数据库并将其复制到另一台机器上.另一台机器也运行 Windows 并具有 MySQL 数据库.两台机器无法通过互联网连接.我该怎么办?怎么可以通过USB卡实现呢?
I have a MySQL Database on mt Windows computer. I need to take one database and copy it to another machine. The other machine also runs windows and has MySQL Database. The two machines cannot be connected through internet. What shall I do? How can that be done through USB-card?
推荐答案
在一个sql文件中创建一个导出DB Mysqldump,并将该sql文件复制到USB card
和import
它进入另一台机器.按照它可以帮助您实现它的步骤进行操作
Make a export DB Mysqldump in a sql file and copy the sql file to USB card
and import
it into the other machine.Follow the steps it would help you to achieve it
制作 mysql 转储
以供参考 参见这里示例:
To make mysql dump
for reference see here
Sample:
mysqldump -u admin -p passwd DB_Name > file/path/filename.sql
import
sql
文件到 mysql DB
as
样本:
mysql > use DB_Name;
mysql >source yourfile.sql
(或)
mysql -u USERNAME -p PASSWORD DATABASE-NAME < file/path/filename.sql
如果有错请指正
这篇关于将 MySQL 数据库复制到另一台机器的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持编程学习网!
本文标题为:将 MySQL 数据库复制到另一台机器


- 如何将 Byte[] 插入 SQL Server VARBINARY 列 2021-01-01
- 使用 Oracle PL/SQL developer 生成测试数据 2021-01-01
- 导入具有可变标题的 Excel 文件 2021-01-01
- 如何将 SonarQube 6.7 从 MySQL 迁移到 postgresql 2022-01-01
- 更改自动增量起始编号? 2021-01-01
- 远程 mySQL 连接抛出“无法使用旧的不安全身份验证连接到 MySQL 4.1+"来自 XAMPP 的错误 2022-01-01
- SQL 临时表问题 2022-01-01
- 在SQL中,如何为每个组选择前2行 2021-01-01
- 如何使用 pip 安装 Python MySQLdb 模块? 2021-01-01
- 以一个值为轴心,但将一行上的数据按另一行分组? 2022-01-01