经常使用sql(持续更新中......)

#查看当前正在执行的sql语句sql

show processlist;ide

#查看用户的权限spa

show grants for real@ '192.168.80.%'索引


#查询表的记录数ssl

select count(*) from table_name;it


#查询表结构table

desc table_name;class

show create table table_name\Gselect


#查询索引sql语句

show index from table_name\G


#修改表的引擎

ALTER TABLE `zaoren_sid` ENGINE=InnoDB;






#更改字段名

alter table tbl_name change 旧字段 新字段 新字段类型;

相关文章
相关标签/搜索