1.只删除表数据,不删除表结构
- truncate table table_name;
复制代码
2.添加用户,授权
- grant all privileges on *.* to server@'%' identified by '123456' with grant option;
复制代码
3.修改密码
- SET PASSWORD FOR 'root'@'%' = PASSWORD("123456");
复制代码
4.查看用户
- select user,host.password from mysql.user;
复制代码
5.查看表结构
6. 查看版本
7.查看字段
- alter table tablename modify column status tinyint(3);
复制代码
|