mariadb/mysql-test/suite/gcol/inc
Marko Mäkelä cffbb17480 MDEV-28933: Per-table unique FOREIGN KEY constraint names
Before MySQL 4.0.18, user-specified constraint names were ignored.
Starting with MySQL 4.0.18, the specified constraint name was
prepended with the schema name and '/'.  Now we are transforming
into a format where the constraint name is prepended with the
dict_table_t::name and the impossible UTF-8 sequence 0xff.
Generated constraint names will be ASCII decimal numbers.

On upgrade, old FOREIGN KEY constraint names will be displayed
without any schema name prefix. They will be updated to the new
format on DDL operations.

dict_foreign_t::sql_id(): Return the SQL constraint name
without any schemaname/tablename\377 or schemaname/ prefix.

row_rename_table_for_mysql(), dict_table_rename_in_cache():
Simplify the logic: Just rename constraints to the new format.

dict_table_get_foreign_id(): Replaces dict_table_get_highest_foreign_id().

innobase_get_foreign_key_info(): Let my_error() refer to erroneous
anonymous constraints as "(null)".

row_delete_constraint(): Try to drop all 3 constraint name variants.

Reviewed by: Thirunarayanan Balathandayuthapani
Tested by: Matthias Leich
2025-07-08 12:30:27 +03:00
..
gcol_blocked_sql_funcs_main.inc allow random_bytes() in virtual columns 2023-08-15 10:16:10 +02:00
gcol_cleanup.inc gcol mysql-test suite from 5.7 2016-12-12 20:27:36 +01:00
gcol_column_def_options.inc Merge 10.6 into 10.7 2022-12-13 18:01:49 +02:00
gcol_dependancies_on_vcol.inc Fix typos in mysql-test/ 2025-04-29 13:53:16 +10:00
gcol_handler.inc gcol mysql-test suite from 5.7 2016-12-12 20:27:36 +01:00
gcol_ins_upd.inc MDEV-28933: Per-table unique FOREIGN KEY constraint names 2025-07-08 12:30:27 +03:00
gcol_keys.inc cleanup: select ... into tests 2025-02-11 20:31:25 +01:00
gcol_non_stored_columns.inc MDEV-11066 use MySQL terminology for "virtual columns" 2016-12-12 20:35:51 +01:00
gcol_partition.inc MDEV-26220 Server crashes with indexed by prefix virtual column 2021-08-02 10:31:22 +02:00
gcol_select.inc MDEV-33281 Optimizer hints Cleanup: fix formatting, rename objects 2025-05-05 12:02:47 +07:00
gcol_supported_sql_funcs.inc gcol mysql-test suite from 5.7 2016-12-12 20:27:36 +01:00
gcol_supported_sql_funcs_main.inc MDEV-19123 Change default charset from latin1 to utf8mb4 2024-07-11 10:21:07 +04:00
gcol_trigger_sp.inc gcol mysql-test suite from 5.7 2016-12-12 20:27:36 +01:00
gcol_unsupported_storage_engines.inc MDEV-11066 use MySQL terminology for "virtual columns" 2016-12-12 20:35:51 +01:00
gcol_view.inc MDEV-4750 follow-up: Reduce disabling innodb_stats_persistent 2021-08-31 13:55:02 +03:00
innodb_v_large_col.inc fix tests after 349ca2be74 2024-05-08 20:01:17 +02:00