Skip to content

ENGINES

xiaoboluo768 edited this page Jun 7, 2020 · 2 revisions
  • 该表提供查询MySQL Server支持的引擎相关的信息
  • 该表是Memory引擎临时表
  • 表定义语句
CREATE TEMPORARY TABLE `ENGINES` (
  `ENGINE` varchar(64) NOT NULL DEFAULT '',
  `SUPPORT` varchar(8) NOT NULL DEFAULT '',
  `COMMENT` varchar(80) NOT NULL DEFAULT '',
  `TRANSACTIONS` varchar(3) DEFAULT NULL,
  `XA` varchar(3) DEFAULT NULL,
  `SAVEPOINTS` varchar(3) DEFAULT NULL
) ENGINE=MEMORY DEFAULT CHARSET=utf8
  • 字段含义如下(该表中所有字段都为 "MySQL extension" 列)
  • ENGINE:引擎名称
  • SUPPORT:表示ENGINE字段显示的引擎在MySQL Server中是否支持
  • COMMENT:表示ENGINE字段显示的引擎相关的解释信息,例如:"Supports transactions, row-level locking, and foreign keys",表示支持事务、支持行级锁,支持外键
  • TRANSACTIONS:表示ENGINE字段显示的引擎是否支持事务
  • XA:表示ENGINE字段显示的引擎是否支持XA事务
  • SAVEPOINTS:表示ENGINE字段显示的引擎是否支持事务保存点
  • 表记录完整字段内容示例
admin@localhost : information_schema 05:43:13> select * from ENGINES;
+--------------------+---------+----------------------------------------------------------------+--------------+------+------------+
| ENGINE            | SUPPORT | COMMENT                                                        | TRANSACTIONS | XA  | SAVEPOINTS |
+--------------------+---------+----------------------------------------------------------------+--------------+------+------------+
| CSV                | YES    | CSV storage engine                                            | NO          | NO  | NO        |
| MRG_MYISAM        | YES    | Collection of identical MyISAM tables                          | NO          | NO  | NO        |
| MyISAM            | YES    | MyISAM storage engine                                          | NO          | NO  | NO        |
| BLACKHOLE          | YES    | /dev/null storage engine (anything you write to it disappears) | NO          | NO  | NO        |
| InnoDB            | DEFAULT | Supports transactions, row-level locking, and foreign keys    | YES          | YES  | YES        |
| PERFORMANCE_SCHEMA | YES    | Performance Schema                                            | NO          | NO  | NO        |
| ARCHIVE            | YES    | Archive storage engine                                        | NO          | NO  | NO        |
| MEMORY            | YES    | Hash based, stored in memory, useful for temporary tables      | NO          | NO  | NO        |
| FEDERATED          | NO      | Federated MySQL storage engine                                | NULL        | NULL | NULL      |
+--------------------+---------+----------------------------------------------------------------+--------------+------+------------+
9 rows in set (0.01 sec)
  • PS:该表中的内容还可以通过show语句查询
# 语法
SHOW [STORAGE] ENGINES

# 示例
root@localhost : information_schema 10:21:05> show engines;
+--------------------+---------+----------------------------------------------------------------+--------------+------+------------+
| Engine            | Support | Comment                                                        | Transactions | XA  | Savepoints |
+--------------------+---------+----------------------------------------------------------------+--------------+------+------------+
| MEMORY            | YES    | Hash based, stored in memory, useful for temporary tables      | NO          | NO  | NO        |
| CSV                | YES    | CSV storage engine                                            | NO          | NO  | NO        |
| MRG_MYISAM        | YES    | Collection of identical MyISAM tables                          | NO          | NO  | NO        |
| BLACKHOLE          | YES    | /dev/null storage engine (anything you write to it disappears) | NO          | NO  | NO        |
| InnoDB            | DEFAULT | Supports transactions, row-level locking, and foreign keys    | YES          | YES  | YES        |
| PERFORMANCE_SCHEMA | YES    | Performance Schema                                            | NO          | NO  | NO        |
| ARCHIVE            | YES    | Archive storage engine                                        | NO          | NO  | NO        |
| MyISAM            | YES    | MyISAM storage engine                                          | NO          | NO  | NO        |
| FEDERATED          | NO      | Federated MySQL storage engine                                | NULL        | NULL | NULL      |
+--------------------+---------+----------------------------------------------------------------+--------------+------+------------+
9 rows in set (0.00 sec)

上一篇:COLUMN_PRIVILEGES表 |下一篇:EVENTS表

Clone this wiki locally