Details
-
Bug
-
Status: In Review (View Workflow)
-
Major
-
Resolution: Unresolved
-
N/A
-
None
Description
create table t (v vector(1) not null, vector(v) distance=euclidean); |
insert into t values (0x31313131); # Optional, fails either way |
alter table t drop index v, add vector(v) distance=cosine; |
show create table t; |
 |
# Cleanup
|
drop table t; |
6038e1babcdfd2c7762dc83a3256afefc0985b84 |
alter table t drop index v, add vector(v) distance=cosine; |
show create table t; |
Table Create Table |
t CREATE TABLE `t` ( |
`v` vector(1) NOT NULL, |
VECTOR KEY `v` (`v`) `distance`=euclidean |
) ENGINE=MyISAM DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_uca1400_ai_ci |
With more data, when index creation normally takes noticeable time, the operation above remains instantaneous, so I suppose it doesn't just preserve the old attribute, but really doesn't do anything.
Workarounds are
- use ALGORITHM=COPY, or
- do it in 2 steps, ALTER .. DROP INDEX followed by ALTER .. ADD VECTOR.
Attachments
Issue Links
- is caused by
-
MDEV-34939 vector search in 11.7
- Closed