First to connect to MySQL command line.
# mysql -u root -p
Password:
view all available databases.
mysql> SHOW DATABASES;
+--------------------+
| Database |
+--------------------+
| information_schema |
| test
honnikery | |
+--------------------+
Select a Database in MySQL
user database-name;
Show Tabels in a Database
show tables;
Show MySQL Database Fields & Field Formats
describe table-name;
Convert MyISAM to INNODB
ALTER TABLE ENGINE=INNODB;
Repair Broken Table(s) in MySQL
repair table broke_table_name;
# mysql -u root -p
Password:
view all available databases.
mysql> SHOW DATABASES;
+--------------------+
| Database |
+--------------------+
| information_schema |
| test
honnikery | |
+--------------------+
Select a Database in MySQL
user database-name;
Show Tabels in a Database
show tables;
Show MySQL Database Fields & Field Formats
describe table-name;
Convert MyISAM to INNODB
ALTER TABLE ENGINE=INNODB;
Repair Broken Table(s) in MySQL
repair table broke_table_name;
No comments:
Post a Comment