User Tools

Site Tools


wiki:mysqldump_tips

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
wiki:mysqldump_tips [2020/12/11 16:00] – created antisawiki:mysqldump_tips [2023/07/03 10:20] (current) – add important box antisa
Line 1: Line 1:
 {{tag>mysql cli}} {{tag>mysql cli}}
 ====== mysqldump tips ====== ====== mysqldump tips ======
 +<WRAP center round important 60%>
 +If you are going to use some of the commands below in crontab, the '%' sign needs to be escaped e.g.
 +''mysqldump -uroot -p --all-databases | bzip2 > db_dump_$(date +\%F).sql.bz2''
 +</WRAP>
  
 ===== Dump only select tables ===== ===== Dump only select tables =====
Line 41: Line 45:
   sed -n -e '/DROP TABLE.*`mytable`/,/UNLOCK TABLES/p' mydump.sql > tabledump.sql   sed -n -e '/DROP TABLE.*`mytable`/,/UNLOCK TABLES/p' mydump.sql > tabledump.sql
  
-    +====== See also ====== 
 +  * [[wiki:mysql_miscellaneous_commands]] 
  
 ====== References ====== ====== References ======
wiki/mysqldump_tips.1607698823.txt.gz · Last modified: 2020/12/11 16:00 by antisa

Except where otherwise noted, content on this wiki is licensed under the following license: CC0 1.0 Universal
CC0 1.0 Universal Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki