MySQL入门操作和常规DML、DDL、DQL使用(2)

每个数据库目录中的db.opt是数据库的信息,表名.frm是表的元信息,表名.ibd是数据信息,其中innodb_file_per_table参数来控制是否单独存储,5.7默认on,之前版本默认off

mysql> show variables like '%per_table%'; +-----------------------+-------+ | Variable_name | Value | +-----------------------+-------+ | innodb_file_per_table | ON | +-----------------------+-------+ 1 row in set (0.01 sec) mysql>

myd .myi是老的MyISAM存储引擎,myi是索引信息

mysql> create table tmp2(id int); Query OK, 0 rows affected (0.02 sec) mysql> show create table tmp; +-------+-----------------------------------------------------------------------------------------+ | Table | Create Table | +-------+-----------------------------------------------------------------------------------------+ | tmp | CREATE TABLE `tmp` ( `id` int(11) DEFAULT NULL ) ENGINE=InnoDB DEFAULT CHARSET=latin1 | +-------+-----------------------------------------------------------------------------------------+ 1 row in set (0.00 sec) mysql>

Linux公社的RSS地址https://www.linuxidc.com/rssFeed.aspx

内容版权声明:除非注明,否则皆为本站原创文章。

转载注明出处:https://www.heiqu.com/0d92493ffb7fa3c40cbce719106350be.html