Skip to content

Instantly share code, notes, and snippets.

@hendrasyp
Last active November 11, 2015 09:23
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save hendrasyp/60cf4605676526040482 to your computer and use it in GitHub Desktop.
Save hendrasyp/60cf4605676526040482 to your computer and use it in GitHub Desktop.
How to Dump and Restore MySQL Database via Console
<?php
// BACKUP / DUMP
// mysqldump -u<username> --password='<password>' <database> <table1,table2,..> > <filename>.<sql/extension>
// RESTORE
// mysqldump -u<username> --password='<password>'; <enter>
// use <databasename>;
// source <filename>.<sql/extension>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment