Fri Jan 08, 2010 1:30 pm - How To Mysqldump Only One Table
#3008
How To Mysqldump Only One Table
Webune Offers dedicated linux server. we also provide web hosting with php and MySQL
if you want to know how you can backup only one table in your whole database you can do it with one command. this command i will show you, you can even zip it to make it smaller:
in the following example, lets say i have this information:
db usename: WEBUSER
db password: DBPASSWORD
database name: MYBLOG
db table: DBTABLE
name of the backup file: MYBACKUPDB
ok use this linux shell command to create it:
SHELL COMMAND:
now, how about to install it - use this command:
SHELL COMMAND:
done
if you want to know how you can backup only one table in your whole database you can do it with one command. this command i will show you, you can even zip it to make it smaller:
in the following example, lets say i have this information:
db usename: WEBUSER
db password: DBPASSWORD
database name: MYBLOG
db table: DBTABLE
name of the backup file: MYBACKUPDB
ok use this linux shell command to create it:
SHELL COMMAND:
mysqldump -u WEBUSER -pDBPASSWORD MYBLOG DBTABLE | gzip > MYBACKUPDB.sql.gz
now, how about to install it - use this command:
SHELL COMMAND:
gunzip < MYBACKUPDB.sql.gz | mysql -u WEBUSER -pDBPASSWORD MYBLOG
done
author: Webune Tutorials