导出：mysqldump -u UserName -p DatabaseName > DatabaseName.sql导入：mysql -u UserName -p DatabaseName < DatabaseName.sql连接：mysql -u UserName -p创建数据库：create database DatabaseName;删除数据库：drop database DatabaseName;查看数据库列表：show databases;选择数据库：use DatabaseName;显示表：show tables;表结构：describe TabelName;表数目：select count(*) from information_schema.tables where table_schema='DatabaseName';查看权限：select * from mysql.user where user='UserName'\G查看权限：show grants for UserName@host;查询用户：select user,host from mysql.user;授权所有权限：grant all privileges on DatabaseName.* to UserName@host identified by 'password';