diff options
Diffstat (limited to 'sql/sql_show.cc')
-rw-r--r-- | sql/sql_show.cc | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/sql/sql_show.cc b/sql/sql_show.cc index c45e27a2794..adba7ab4d33 100644 --- a/sql/sql_show.cc +++ b/sql/sql_show.cc @@ -6386,6 +6386,19 @@ static int get_schema_constraints_record(THD *thd, TABLE_LIST *tables, } } + // Table check constraints + for ( uint i = 0; i < show_table->s->table_check_constraints; i++ ) + { + Virtual_column_info *check = show_table->check_constraints[ i ]; + + if ( store_constraints( thd, table, db_name, table_name, check->name.str, + check->name.length, + STRING_WITH_LEN( "CHECK" ) ) ) + { + DBUG_RETURN( 1 ); + } + } + show_table->file->get_foreign_key_list(thd, &f_key_list); FOREIGN_KEY_INFO *f_key_info; List_iterator_fast<FOREIGN_KEY_INFO> it(f_key_list); |