MySQL - 系统表 - information_schema

INFORMATION_SCHEMA provides access to database metadata, information about the MySQL server such as the name of a database or table, the data type of a column, or access privileges. Other terms that are sometimes used for this information are data dictionary and system catalog.

CHARACTER_SETS
available character sets.

CHECK_CONSTRAINTS
CHECK constraints defined on tables.

COLLATIONS
collations for each character set.

COLLATION_CHARACTER_SET_APPLICABILITY
character set is applicable for what collation.

COLUMNS
information about columns in tables

COLUMN_PRIVILEGES
information about column privileges

COLUMN_STATISTICS
access to histogram statistics for column values.

ENGINES
information about storage engines.

+--------------------+---------+----------------------------------------------------------------+--------------+------+------------+
| ENGINE             | SUPPORT | COMMENT                                                        | TRANSACTIONS | XA   | SAVEPOINTS |
+--------------------+---------+----------------------------------------------------------------+--------------+------+------------+
| FEDERATED          | NO      | Federated MySQL storage engine                                 | NULL         | NULL | NULL       |
| MEMORY             | YES     | Hash based, stored in memory, useful for temporary tables      | NO           | NO   | NO         |
| InnoDB             | DEFAULT | Supports transactions, row-level locking, and foreign keys     | YES          | YES  | YES        |
| PERFORMANCE_SCHEMA | YES     | Performance Schema                                             | NO           | NO   | NO         |
| MyISAM             | YES     | MyISAM 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         |
| CSV                | YES     | CSV storage engine                                             | NO           | NO   | NO         |
| ARCHIVE            | YES     | Archive storage engine                                         | NO           | NO   | NO         |
+--------------------+---------+----------------------------------------------------------------+--------------+------+------------+

EVENTS
information about Event Manager events(Event Scheduler)

FILES
information about the files in which MySQL tablespace data is stored.

INNODB_BUFFER_PAGE
information about each page in the InnoDB buffer pool.

INNODB_BUFFER_PAGE_LRU
information about the pages in the InnoDB buffer pool; in particular, how they are ordered in the LRU list that determines which pages to evict from the buffer pool when it becomes full.

INNODB_BUFFER_POOL_STATS
much of the same buffer pool information provided in SHOW ENGINE INNODB STATUS output. Much of the same information may also be obtained using InnoDB buffer pool server status variables.

INNODB_CACHED_INDEXES
the number of index pages cached in the InnoDB buffer pool for each index.

INNODB_CMP
status information on operations related to compressed InnoDB tables.

INNODB_CMPMEM
status information on compressed pages within the InnoDB buffer pool.

INNODB_CMPMEM_RESET
status information on compressed pages within the InnoDB buffer pool.

INNODB_CMP_PER_INDEX
status information on operations related to compressed InnoDB tables and indexes, with separate statistics for each combination of database, table, and index, to help you evaluate the performance and usefulness of compression for specific tables.

INNODB_CMP_PER_INDEX_RESET
status information on operations related to compressed InnoDB tables and indexes, with separate statistics for each combination of database, table, and index, to help you evaluate the performance and usefulness of compression for specific tables.

INNODB_CMP_RESET
status information on operations related to compressed InnoDB tables.

INNODB_COLUMNS
metadata about InnoDB table columns.

INNODB_DATAFILES
data file path information for InnoDB file-per-table and general tablespaces.

INNODB_FIELDS
metadata about the key columns (fields) of InnoDB indexes.

INNODB_FOREIGN
metadata about InnoDB foreign keys.

INNODB_FOREIGN_COLS
status information about InnoDB foreign key columns.

INNODB_FT_BEING_DELETED
a snapshot of the INNODB_FT_DELETED table; it is used only during an OPTIMIZE TABLE maintenance operation.

INNODB_FT_CONFIG
metadata about the FULLTEXT index and associated processing for an InnoDB table.

INNODB_FT_DEFAULT_STOPWORD
a list of stopwords that are used by default when creating a FULLTEXT index on InnoDB tables. For information about the default InnoDB stopword list and how to define your own stopword lists

INNODB_FT_DELETED
stores rows that are deleted from the FULLTEXT index for an InnoDB table.

INNODB_FT_INDEX_CACHE
token information about newly inserted rows in a FULLTEXT index.

INNODB_FT_INDEX_TABLE
information about the inverted index used to process text searches against the FULLTEXT index of an InnoDB table.

INNODB_INDEXES
metadata about InnoDB indexes.

INNODB_METRICS
a wide variety of InnoDB performance information, complementing the specific focus areas of the Performance Schema tables for InnoDB.

INNODB_TABLES
metadata about InnoDB tables.

INNODB_TABLESPACES
metadata about InnoDB file-per-table, general, and undo tablespaces.

INNODB_TABLESPACES_BRIEF
space ID, name, path, flag, and space type metadata for file-per-table, general, undo, and system tablespaces.

INNODB_TABLESTATS
a view of low-level status information about InnoDB tables.

INNODB_TEMP_TABLE_INFO
information about user-created InnoDB temporary tables that are active in an InnoDB instance

INNODB_TRX
information about every transaction (excluding read-only transactions) currently executing inside InnoDB, including whether the transaction is waiting for a lock, when the transaction started, and the SQL statement the transaction is executing, if any.

INNODB_VIRTUAL
metadata about InnoDB virtual generated columns and columns upon which virtual generated columns are based.

KEY_COLUMN_USAGE
which key columns have constraints

OPTIMIZER_TRACE
information produced by the optimizer tracing capability for traced statements.

SET optimizer_trace="enabled=on";
SELECT ...; # your query here
SELECT * FROM INFORMATION_SCHEMA.OPTIMIZER_TRACE;
# possibly more queries...
# When done with tracing, disable it:
SET optimizer_trace="enabled=off";

PARAMETERS
information about parameters for stored routines (stored procedures and stored functions), and about return values for stored functions.

PARTITIONS
information about table partitions

PLUGINS
information about server plugins.

PROCESSLIST
information about which threads are running.

PROFILING
statement profiling information. Its contents correspond to the information produced by the SHOW PROFILE and SHOW PROFILES statements

REFERENTIAL_CONSTRAINTS
information about foreign keys.

RESOURCE_GROUPS
access to information about resource groups

ROUTINES
information about stored routines (stored procedures and stored functions)

SCHEMATA
A schema is a database, so the SCHEMATA table provides information about databases.

SCHEMA_PRIVILEGES
information about schema (database) privileges.

STATISTICS
information about table indexes.
Columns in STATISTICS that represent table statistics hold cached values.

ST_GEOMETRY_COLUMNS
information about table columns that store spatial data

ST_SPATIAL_REFERENCE_SYSTEMS
information about available spatial reference systems for spatial data.

TABLES
information about tables in databases.

TABLESPACES
information about active MySQL Cluster tablespaces.

TABLE_CONSTRAINTS
which tables have constraints.

TABLE_PRIVILEGES
information about table privileges

TRIGGERS
information about triggers

USER_PRIVILEGES
information about global privileges

VIEWS
information about views in databases

发布了213 篇原创文章 · 获赞 7 · 访问量 6万+

猜你喜欢

转载自blog.csdn.net/chuckchen1222/article/details/101060017