- Time to save your precious work:
mysqldump -u root -p my_test_db > my_test_db.out
- Now drop the table
mysql>drop table table1;
- Now drop the whole database my_test_db:
mysql>drop database my_test_db;
- create the db again:
mysql>create database my_test_db;
- Replay the backup
mysql -u root -p my_test_db < my_test_db.out
We're through, check the clock.
Btw: If you're going to be asked what SQL stands for, don't disgrace yourself. It means: Structured Query Language.
If you'll get this one:
ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: NO)
then you've already set the password, and need to use the
-u for user and the
-p for password switch.