Is there any way to copy database structure without data in MySQL, so the new database will be the same as it is copied from, but with empty tables.
After getting some s
mysqldump -u user -ppass -d olddb | mysql -u user -ppass -D newdb
The new database must already exist. The -d flag in the mysqldump command prevents copying of data.
-d
There's no space between the flag -p and the password.
-p