1: SELECT `SCHEMA_NAME` FROM `information_schema`.`SCHEMATA`; 查询sql中的数据库名
2: select * from forum.t_user; //跨库查询,数据库名.表名
3: alter table teacher add index(name,password) //为数据表创建索引,提高查询速度
4:设置数据库,高并发访问: set global max_connections=10000 //设置最大线程连接数
5:sql两阶段加锁, 增长阶段》一直加锁, 缩减阶段》释放锁。