当前位置:网站首页>Mysql database table export and import with binary
Mysql database table export and import with binary
2022-07-03 06:03:00 【UU_ Yang】
【mysqldump】 export sql Script , Out of commission select Export some fields
export
>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"
Import
>mysql -hlocalhost -P3307 -uroot -p123456 mydb <export.sql
Or first mysql Sign in , Switch DB, perform source export.sql
【sql】 Derived data , have access to select sentence
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';
Import
load data infile 'C:/ProgramData/MySQL/MySQL Server 5.7/Uploads/out.csv' into table mydb.mytable
【mysql】 Derived data , have access to select
mysql -h192.168.1.12 -P3307 -uroot -p123456 test -e "select id,name,age from usertable" > d:\users.csv
边栏推荐
- [together Shangshui Shuo series] day 7 content +day8
- [teacher Zhao Yuqiang] MySQL high availability architecture: MHA
- Intel's new GPU patent shows that its graphics card products will use MCM Packaging Technology
- C 语言文件操作函数大全 (超详细)
- 多线程与高并发(7)——从ReentrantLock到AQS源码(两万字大章,一篇理解AQS)
- [teacher Zhao Yuqiang] index in mongodb (Part 2)
- Kubernetes resource object introduction and common commands (V) - (configmap)
- Download the corresponding version of chromedriver
- Why should there be a firewall? This time xiaowai has something to say!!!
- BeanDefinitionRegistryPostProcessor
猜你喜欢
Alibaba cloud OOS file upload
从小数据量 MySQL 迁移数据到 TiDB
Multithreading and high concurrency (7) -- from reentrantlock to AQS source code (20000 words, one understanding AQS)
QT read write excel -- qxlsx insert chart 5
Redhat7系统root用户密码破解
[function explanation (Part 1)] | | knowledge sorting + code analysis + graphic interpretation
Detailed explanation of contextclassloader
How to create and configure ZABBIX
Kubernetes resource object introduction and common commands (V) - (configmap)
Qt读写Excel--QXlsx插入图表5
随机推荐
C 语言文件操作函数大全 (超详细)
卷积神经网络CNN中的卷积操作详解
[teacher Zhao Yuqiang] the most detailed introduction to PostgreSQL architecture in history
JS implements the problem of closing the current child window and refreshing the parent window
[teacher Zhao Yuqiang] index in mongodb (Part 2)
Kubernetes notes (I) kubernetes cluster architecture
Detailed explanation of contextclassloader
[together Shangshui Shuo series] day 7 content +day8
Kubernetes notes (IX) kubernetes application encapsulation and expansion
Why should there be a firewall? This time xiaowai has something to say!!!
70 shell script interview questions and answers
项目总结--01(接口的增删改查;多线程的使用)
1. Somme des deux nombres
The server data is all gone! Thinking caused by a RAID5 crash
Kubernetes notes (VI) kubernetes storage
MySQL startup error: several solutions to the server quit without updating PID file
Redis cannot connect remotely.
理解 期望(均值/估计值)和方差
MySQL 5.7.32-winx64 installation tutorial (support installing multiple MySQL services on one host)
Crontab command usage