#!/bin/sh
DBNAME="DBName"
DBUSER="root"
DBPWD="YourPassword"
for t in $(mysql -u$DBUSER -p$DBPWD --batch --column-names=false -e "show tables" $DBNAME);
do
echo "Converting table $t"
mysql -u$DBUSER -p$DBPWD -e "alter table $t engine=MyISAM" $DBNAME;
done
No comments:
Post a Comment