MySQL 8.0.40
Source Code Documentation
|
Classes | |
class | Select_lex_builder |
This class provide framework to build a Query_block using ParseTree nodes. More... | |
class | Table_statistics |
The class hold dynamic table statistics for a table. More... | |
class | Tablespace_statistics |
The class hold dynamic table statistics for a table. More... | |
Enumerations | |
enum class | enum_table_stats_type { TABLE_ROWS , TABLE_AVG_ROW_LENGTH , DATA_LENGTH , MAX_DATA_LENGTH , INDEX_LENGTH , DATA_FREE , AUTO_INCREMENT , CHECKSUM , TABLE_UPDATE_TIME , CHECK_TIME , INDEX_COLUMN_CARDINALITY } |
enum class | enum_tablespace_stats_type { TS_ID , TS_TYPE , TS_LOGFILE_GROUP_NAME , TS_LOGFILE_GROUP_NUMBER , TS_FREE_EXTENTS , TS_TOTAL_EXTENTS , TS_EXTENT_SIZE , TS_INITIAL_SIZE , TS_MAXIMUM_SIZE , TS_AUTOEXTEND_SIZE , TS_VERSION , TS_ROW_FORMAT , TS_DATA_FREE , TS_STATUS , TS_EXTRA } |
Functions | |
bool | create_system_views (THD *thd) |
Create INFORMATION_SCHEMA system views. More... | |
bool | store_server_I_S_metadata (THD *thd) |
Store the server I_S table metadata into dictionary, once during MySQL server bootstrap. More... | |
bool | update_I_S_metadata (THD *thd) |
Store I_S table metadata into dictionary, during MySQL server startup. More... | |
bool | store_dynamic_plugin_I_S_metadata (THD *thd, st_plugin_int *plugin_int) |
Store dynamic I_S plugin table metadata into dictionary, during INSTALL command execution. More... | |
bool | remove_I_S_view_metadata (THD *thd, const dd::String_type &view_name) |
Remove I_S view metadata from dictionary. More... | |
bool | initialize (THD *thd) |
Initialize INFORMATION_SCHEMA system views. More... | |
bool | init_non_dd_based_system_view (THD *thd) |
Initialize non DD based INFORMATION_SCHEMA system views. More... | |
bool | get_I_S_view_definition (const dd::String_type &schema_name, const dd::String_type &view_name, dd::String_type *definition) |
Get create view definition for the given I_S system view. More... | |
Query_block * | build_show_character_set_query (const POS &pos, THD *thd, const String *wild, Item *where_cond) |
Build a substitute query for SHOW CHARSETS. More... | |
Query_block * | build_show_collation_query (const POS &pos, THD *thd, const String *wild, Item *where_cond) |
Build a substitute query for SHOW COLLATION. More... | |
Query_block * | build_show_databases_query (const POS &pos, THD *thd, String *wild, Item *where_cond) |
Build a substitute query for SHOW DATABASES. More... | |
static bool | add_table_status_fields (Select_lex_builder *query, bool alias_as_alias) |
Add fields required by SHOW TABLE STATUS. More... | |
Query_block * | build_show_tables_query (const POS &pos, THD *thd, String *wild, Item *where_cond, bool include_status_fields) |
Build a substitute query for SHOW TABLES / TABLE STATUS. More... | |
Query_block * | build_show_columns_query (const POS &pos, THD *thd, Table_ident *table_ident, const String *wild, Item *where_cond) |
Build a substitute query for SHOW COLUMNS/FIELDS OR DESCRIBE. More... | |
Query_block * | build_show_keys_query (const POS &pos, THD *thd, Table_ident *table_ident, Item *where_cond) |
Build a substitute query for SHOW INDEX|KEYS|INDEXES. More... | |
Query_block * | build_show_triggers_query (const POS &pos, THD *thd, String *wild, Item *where_cond) |
Build a substitute query for SHOW TRIGGERS. More... | |
Query_block * | build_show_procedures_query (const POS &pos, THD *thd, String *wild, Item *where_cond) |
Build a substitute query for SHOW PROCEDURE/FUNCTION STATUS. More... | |
Query_block * | build_show_events_query (const POS &pos, THD *thd, String *wild, Item *where_cond) |
Build a substitute query for SHOW EVENTS. More... | |
bool | update_table_stats (THD *thd, Table_ref *table) |
Get dynamic table statistics of a table and store them into mysql.table_stats. More... | |
bool | update_index_stats (THD *thd, Table_ref *table) |
Get dynamic index statistics of a table and store them into mysql.index_stats. More... | |
bool | convert_table_name_case (char *db, char *table_name) |
If the db is 'information_schema' then convert 'db' to lowercase and 'table_name' to upper case. More... | |
Variables | |
static const uint | IS_DD_VERSION = 80030 |
The version of the current information_schema system views. More... | |
static const Query_options | options |
|
strong |
|
strong |
|
static |
Add fields required by SHOW TABLE STATUS.
query | - Select_lex_builder to which we add fields. |
alias_as_alias | - Add select items of the form, 'alias AS alias'. This is required for top level query, as the real field names would be valid only the subquery that we are building for SHOW TABLE STATUS. Check comments in sql/dd/show.h for more details. |
Query_block * dd::info_schema::build_show_character_set_query | ( | const POS & | pos, |
THD * | thd, | ||
const String * | wild, | ||
Item * | where_cond | ||
) |
Build a substitute query for SHOW CHARSETS.
For command like,
We build following,
pos | - YYLTYPE position of parsing context. |
thd | - Current thread. |
wild | - The value of LIKE clause. |
where_cond | - <where_clause> clause provided by user. |
Query_block * dd::info_schema::build_show_collation_query | ( | const POS & | pos, |
THD * | thd, | ||
const String * | wild, | ||
Item * | where_cond | ||
) |
Build a substitute query for SHOW COLLATION.
For command like,
We build following,
pos | - YYLTYPE position of parsing context. |
thd | - Current thread. |
wild | - The value of LIKE clause. |
where_cond | - <where_clause> clause provided by user. |
Query_block * dd::info_schema::build_show_columns_query | ( | const POS & | pos, |
THD * | thd, | ||
Table_ident * | table_ident, | ||
const String * | wild, | ||
Item * | where_cond | ||
) |
Build a substitute query for SHOW COLUMNS/FIELDS OR DESCRIBE.
For command like,
We build following,
Note that the thd->lex->verbose == true would mean user has provide keyword 'FULL'.
pos | - YYLTYPE position of parsing context. |
thd | - Current thread. |
table_ident | - Database and Table name of table being used. |
wild | - The value of LIKE clause. |
where_cond | - <where_clause> clause provided by user. |
Query_block * dd::info_schema::build_show_databases_query | ( | const POS & | pos, |
THD * | thd, | ||
String * | wild, | ||
Item * | where_cond | ||
) |
Build a substitute query for SHOW DATABASES.
For command like,
We build following,
pos | - YYLTYPE position of parsing context. |
thd | - Current thread. |
wild | - The value of LIKE clause. |
where_cond | - <where_clause> clause provided by user. |
Query_block * dd::info_schema::build_show_events_query | ( | const POS & | pos, |
THD * | thd, | ||
String * | wild, | ||
Item * | where_cond | ||
) |
Build a substitute query for SHOW EVENTS.
For command like,
We build following,
pos | - YYLTYPE position of parsing context. |
thd | - Current thread. |
wild | - The value of LIKE clause. |
where_cond | - <where_clause> clause provided by user. |
Query_block * dd::info_schema::build_show_keys_query | ( | const POS & | pos, |
THD * | thd, | ||
Table_ident * | table_ident, | ||
Item * | where_cond | ||
) |
Build a substitute query for SHOW INDEX|KEYS|INDEXES.
For command like,
We build following,
pos | - YYLTYPE position of parsing context. |
thd | - Current thread. |
table_ident | - Database and Table name of table being used. |
where_cond | - <where_clause> clause provided by user. |
Query_block * dd::info_schema::build_show_procedures_query | ( | const POS & | pos, |
THD * | thd, | ||
String * | wild, | ||
Item * | where_cond | ||
) |
Build a substitute query for SHOW PROCEDURE/FUNCTION STATUS.
For command like,
We build following,
pos | - YYLTYPE position of parsing context. |
thd | - Current thread. |
wild | - The value of LIKE clause. |
where_cond | - <where_clause> clause provided by user. |
Query_block * dd::info_schema::build_show_tables_query | ( | const POS & | pos, |
THD * | thd, | ||
String * | wild, | ||
Item * | where_cond, | ||
bool | include_status_fields | ||
) |
Build a substitute query for SHOW TABLES / TABLE STATUS.
For command like,
We build following,
Note that the thd->lex->verbose == true would mean user has provide keyword 'FULL'.
pos | - YYLTYPE position of parsing context. |
thd | - Current thread. |
wild | - The value of LIKE clause. |
where_cond | - <where_clause> clause provided by user. |
include_status_fields | - If we are handling SHOW TABLE STATUS |
Query_block * dd::info_schema::build_show_triggers_query | ( | const POS & | pos, |
THD * | thd, | ||
String * | wild, | ||
Item * | where_cond | ||
) |
Build a substitute query for SHOW TRIGGERS.
For command like,
We build following,
pos | - YYLTYPE position of parsing context. |
thd | - Current thread. |
wild | - The value of LIKE clause. |
where_cond | - <where_clause> clause provided by user. |
bool dd::info_schema::convert_table_name_case | ( | char * | db, |
char * | table_name | ||
) |
If the db is 'information_schema' then convert 'db' to lowercase and 'table_name' to upper case.
Mainly because all information schema tables are stored in upper case in server.
db | Database name |
table_name | Table name. |
bool dd::info_schema::create_system_views | ( | THD * | thd | ) |
Create INFORMATION_SCHEMA system views.
thd | Thread context. |
bool dd::info_schema::get_I_S_view_definition | ( | const dd::String_type & | schema_name, |
const dd::String_type & | view_name, | ||
dd::String_type * | definition | ||
) |
Get create view definition for the given I_S system view.
schema_name | Schema name. |
view_name | I_S view name. |
definition | [out] The CREATE VIEW command to create system view. A pointer to a preallocated string should be supplied. |
bool dd::info_schema::init_non_dd_based_system_view | ( | THD * | thd | ) |
Initialize non DD based INFORMATION_SCHEMA system views.
thd | Thread context. |
bool dd::info_schema::initialize | ( | THD * | thd | ) |
Initialize INFORMATION_SCHEMA system views.
thd | Thread context. |
bool dd::info_schema::remove_I_S_view_metadata | ( | THD * | thd, |
const dd::String_type & | view_name | ||
) |
Remove I_S view metadata from dictionary.
This is used UNINSTALL and server restart procedure when I_S version is changed.
thd | Thread context. |
view_name | I_S view name of which the metadata is to be stored. |
bool dd::info_schema::store_dynamic_plugin_I_S_metadata | ( | THD * | thd, |
st_plugin_int * | plugin_int | ||
) |
Store dynamic I_S plugin table metadata into dictionary, during INSTALL command execution.
thd | Thread context. |
plugin_int | I_S Plugin of which the metadata is to be stored. |
bool dd::info_schema::store_server_I_S_metadata | ( | THD * | thd | ) |
Store the server I_S table metadata into dictionary, once during MySQL server bootstrap.
thd | Thread context. |
bool dd::info_schema::update_I_S_metadata | ( | THD * | thd | ) |
Store I_S table metadata into dictionary, during MySQL server startup.
thd | Thread context. |
Get dynamic index statistics of a table and store them into mysql.index_stats.
thd | Thread. |
table | Table_ref pointing to table info. |
Get dynamic table statistics of a table and store them into mysql.table_stats.
thd | Thread. |
table | Table_ref pointing to table info. |
|
static |
The version of the current information_schema system views.
This version number is stored on disk in the data dictionary. Every time the information_schema structure changes, this version number must change.
The numbering to use is the MySQL version number of the first MySQL version that published a given database schema. The format is Mmmdd with M=Major, m=minor, d=dot, so that MySQL 8.0.4 is encoded as 80004.
Historical I_S version number published:
Introduced in MySQL 8.0.0 by WL#6599. Never published in a GA version.
Changes from version 1:
external_language
to mysql
.routines
and update information_schema
.routines
to reflect this column.Changes from version 80011:
Changes from version 80012
information_schema
.st_units_of_measure
with columns UNIT_NAME
, CONVERSION_FACTOR
, DESCRIPTION
, and UNIT_TYPE
. This view contains the supported spatial units.There are no changes from version 80013. Hence server version 80014 used I_S version 80013.
There are no changes from version 80014. Hence server version 80015 used I_S version 80013.
Changes from version 80015.
Changes from version 80016:
Changes from version 80017:
Bug#28278220: wrong column type , view , binary Changes type of following I_S table column's KEY_COLUMN_USAGE: CONSTRAINT_NAME, POSITION_IN_UNIQUE_CONSTRAINT, REFERENCED_TABLE_SCHEMA, FIELD_REFERENCED_TABLE_NAME, REFERENCED_COLUMN_NAME
TABLE_CONSTRAINTS: CONSTRAINT_NAME. Column metadata of views on these system views or tables created using CREATE TABLE SELECT from these system views will not be similar to one created with previous version of system views.
Changes from version 80018:
80020: Published by mistake in server version 8.0.19. To correct this, we set the IS version number to 800201 in mysql server version 8.0.20.
Changes from version 80018:
Changes from version 80020:
Changes from version 800201:
Changes from version 80021:
Changes from version 80022:
There are no changes from version 80023. Hence server versions 80024..80028 uses I_S version 80023.
Changes from version 80023:
Changes from version 80029:
Changes from version 80030:
|
static |