当前位置:网站首页>MySQL带二进制的库表导出导入
MySQL带二进制的库表导出导入
2022-07-03 06:02:00 【UU_Yang】
【mysqldump】导出sql脚本,不能使用select导出部分字段
导出
>mysqldump -hlocalhost -P3307 -uroot -p123456 mydb mytable --where="id = 412123456" --hex-blob --add-drop-table=false --add-locks=false --no-create-info=true>"d:\export.sql"
导入
>mysql -hlocalhost -P3307 -uroot -p123456 mydb <export.sql
或者先mysql登录,切换DB,执行source export.sql
【sql】导出数据,可以使用select语句
select id, c1, c2, c3, c4, c5, c6, c7, c8 from mydb.mytable limit 100 into outfile
'C:/ProgramData/MySQL/MySQL Server 5.7/Uploads/out.csv' fields Terminated by',' lines terminated by'\r\n';
导入
load data infile 'C:/ProgramData/MySQL/MySQL Server 5.7/Uploads/out.csv' into table mydb.mytable
【mysql】导出数据,可以使用select
mysql -h192.168.1.12 -P3307 -uroot -p123456 test -e "select id,name,age from usertable" > d:\users.csv
边栏推荐
- Deep learning, thinking from one dimensional input to multi-dimensional feature input
- [branch and cycle] | | super long detailed explanation + code analysis + a trick game
- [advanced pointer (2)] | [function pointer, function pointer array, callback function] key analysis + code explanation
- Detailed explanation of findloadedclass
- Qt读写Excel--QXlsx插入图表5
- Kubernetes notes (IV) kubernetes network
- 伯努利分布,二项分布和泊松分布以及最大似然之间的关系(未完成)
- MySQL startup error: several solutions to the server quit without updating PID file
- 深度学习,从一维特性输入到多维特征输入引发的思考
- 从小数据量分库分表 MySQL 合并迁移数据到 TiDB
猜你喜欢

Jedis source code analysis (I): jedis introduction, jedis module source code analysis

Understand the first prediction stage of yolov1

Life is a process of continuous learning
![[trivia of two-dimensional array application] | [simple version] [detailed steps + code]](/img/84/98c1220d0f7bc3a948125ead6ff3d9.jpg)
[trivia of two-dimensional array application] | [simple version] [detailed steps + code]
![[function explanation (Part 1)] | | knowledge sorting + code analysis + graphic interpretation](/img/c2/991b8febd262cf9237017adc9d1221.jpg)
[function explanation (Part 1)] | | knowledge sorting + code analysis + graphic interpretation

Understand one-way hash function

一起上水碩系列】Day 9

Redhat7 system root user password cracking
![[video of Teacher Zhao Yuqiang's speech on wot] redis high performance cache and persistence](/img/a7/2140744ebad9f1dc0a609254cc618e.jpg)
[video of Teacher Zhao Yuqiang's speech on wot] redis high performance cache and persistence
![[together Shangshui Shuo series] day 7 content +day8](/img/fc/74b12addde3a4d3480e98f8578a969.png)
[together Shangshui Shuo series] day 7 content +day8
随机推荐
从小数据量分库分表 MySQL 合并迁移数据到 TiDB
Apt update and apt upgrade commands - what is the difference?
Final review (Day5)
Detailed explanation of findloadedclass
Redis cannot connect remotely.
Intel's new GPU patent shows that its graphics card products will use MCM Packaging Technology
@Import annotation: four ways to import configuration classes & source code analysis
理解 期望(均值/估计值)和方差
Disruptor learning notes: basic use, core concepts and principles
Kubernetes notes (IX) kubernetes application encapsulation and expansion
It is said that the operation and maintenance of shell scripts are paid tens of thousands of yuan a month!!!
Bio, NiO, AIO details
Simple handwritten ORM framework
PHP用ENV获取文件参数的时候拿到的是字符串
Apache+php+mysql environment construction is super detailed!!!
Download the corresponding version of chromedriver
Leetcode problem solving summary, constantly updating!
How does win7 solve the problem that telnet is not an internal or external command
Kubernetes resource object introduction and common commands (V) - (configmap)
Clickhouse learning notes (2): execution plan, table creation optimization, syntax optimization rules, query optimization, data consistency