I have a database in .sql format, while restore the database to localhost all tables have unknown data. how can i delete all tables data before or after import.
i am using windows 7. mysql server 5.5
phpmyadmin has an option for this task.
Select the database, you wish to export with empty tables
Click on Export
Select Custom in Export Method
Scroll down to Format-specfic options
Select Structure instead of Structure and data
Click on Go
That's all there is to it.
if you have access to PhpMyAdmin http://localhost/phpmyadmin/
on your localhost simply login and drop the tables in the database you wish to import SQL dumps.
Then import the SQL dump file (.sql)
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.