5.数据库管理操作


1.MySql的存储引擎

2.MyISAM和InnoDB、MEMORY存储引擎

3.查看表结构:desc goods;

查看数据库中的用户表:show tabales:

查看用户表创建的基本语句:show create table goods;

4.修改表:alter  table  goods  rename tb_goods;

删除表:drop

修改某列数据类型:modify     --->alter table tb_goods  modify   type   char(30);

对列的名称修改:alter  table tb_goods  change name  g_name  varchar(30);

通过索引添加唯一性

查询语句:

select distinct type from goods; 去重

带or的多条件查询