1
0
mirror of https://github.com/MariaDB/server.git synced 2025-08-08 11:22:35 +03:00

InnoDB support for hlindexes and mhnsw

* mhnsw:
  * use primary key, innodb loves and (and the index cannot have dupes anyway)
    * MyISAM is ok with that, performance-wise
  * must be ha_rnd_init(0) because we aren't going to scan
    * MyISAM resets the position on ha_rnd_init(0) so query it before
    * oh, and use the correct handler, just in case
  * HA_ERR_RECORD_IS_THE_SAME is no error
* innodb:
  * return ref_length on create
  * don't assume table->pos_in_table_list is set
  * ok, assume away, but only for system versioned tables
* set alter_info on create (InnoDB needs to check for FKs)
* pair external_lock/external_unlock correctly
This commit is contained in:
Sergei Golubchik
2024-06-08 11:03:08 +02:00
parent 2efd9b17ba
commit 25b4000290
6 changed files with 39 additions and 17 deletions

View File

@@ -6416,9 +6416,12 @@ int ha_create_table(THD *thd, const char *path, const char *db,
DBUG_ASSERT(share.key_info[share.keys].algorithm == HA_KEY_ALG_VECTOR);
TABLE_SHARE index_share;
char file_name[FN_REFLEN+1];
Alter_info index_ainfo;
HA_CREATE_INFO index_cinfo;
char *path_end= strmov(file_name, path);
index_cinfo.alter_info= &index_ainfo;
if ((error= share.path.length > sizeof(file_name) - HLINDEX_BUF_LEN))
goto err;