Reverse detail from Kakelbont MS 1, a fifteenth-century French Psalter. This image is in the public domain. Daniel Paul O'Donnell

Forward to Navigation

MySQL cheatsheet

Posted: Aug 27, 2012 13:08;
Last Modified: Aug 27, 2012 14:08
Keywords:

---

From http://www.patrickpatoray.com/?Page=30

MySQL Dump/Restore

Dump ALL MySQL Databases

mysqldump —user=XXXXXXXX —password=XXXXXXX -A > /PATH/TO/DUMPFILE.SQL

Dump Individual or Multiple MySQL Databases

mysqldump —user=XXXXXXXX —password=XXXXXXX —databases DB_NAME1 DB_NAME2 DB_NAME3 > /PATH/TO/DUMPFILE.SQL

Dump only certain tables from a MySQL Database

mysqldump —user=XXXXXXXX —password=XXXXXXXX —databases DB_NAME —tables TABLE_NAME > /PATH/TO/DUMPFILE.SQL

Restoring dbase

  1. Use the following procedure to reload the contents of a database:
  2. Unzip the backup file you wish to use.
  3. Open it up and pull out only the information that you will need.
  4. Save this text file.
  5. Use the following command to feed back in the contents of a text file:
mysql —verbose —user=XXXXXXXX —password=XXXXXXXX DB_NAME < /PATH/TO/DUMPFILE.SQL
----  

Comment

:
:

:

Textile help

Back to content

Search my site

Sections

Current teaching

Recent changes to this site

Tags

anglo-saxon studies, caedmon, citation practice, composition, computers, digital humanities, digital pedagogy, grammar, history, moodle, old english, pedagogy, research, students, study tips, teaching, tips, tutorials, unessay, universities

See all...

Follow me on Twitter