mirror of
https://github.com/MariaDB/server.git
synced 2026-01-06 05:22:24 +03:00
Check index column sizes in a better way (bug #13315).
This commit is contained in:
@@ -2517,6 +2517,12 @@ ha_innobase::open(
|
||||
DBUG_RETURN(0);
|
||||
}
|
||||
|
||||
uint
|
||||
ha_innobase::max_supported_key_part_length() const
|
||||
{
|
||||
return(DICT_MAX_INDEX_COL_LEN - 1);
|
||||
}
|
||||
|
||||
/**********************************************************************
|
||||
Closes a handle to an InnoDB table. */
|
||||
|
||||
@@ -4674,6 +4680,9 @@ create_index(
|
||||
0, prefix_len);
|
||||
}
|
||||
|
||||
/* Even though we've defined max_supported_key_part_length, we
|
||||
still do our own checking using field_lengths to be absolutely
|
||||
sure we don't create too long indexes. */
|
||||
error = row_create_index_for_mysql(index, trx, field_lengths);
|
||||
|
||||
error = convert_error_code_to_mysql(error, NULL);
|
||||
|
||||
@@ -110,7 +110,7 @@ class ha_innobase: public handler
|
||||
but currently MySQL does not work with keys
|
||||
whose size is > MAX_KEY_LENGTH */
|
||||
uint max_supported_key_length() const { return 3500; }
|
||||
uint max_supported_key_part_length() const { return 3500; }
|
||||
uint max_supported_key_part_length() const;
|
||||
const key_map *keys_to_use_for_scanning() { return &key_map_full; }
|
||||
bool has_transactions() { return 1;}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user