Bug #109242 CREATE FULLTEXT INDEX fails with ERROR 1062 (23000): Duplicate entry 'NULL-NULL'
Submitted: 29 Nov 2022 21:04 Modified: 30 Nov 2022 4:42
Reporter: E M Email Updates:
Status: Verified Impact on me:
Category:MySQL Server: DDL Severity:S2 (Serious)
Version: 8.0.31 OS:Ubuntu
Assigned to: CPU Architecture:x86 (x86_64)
Tags: regression

[29 Nov 2022 21:04] E M
Dropping then recreating a fulltext index on two columns with ~10,000 rows of random  data usually fails (making the columns NOT NULL changes the value cited in the error from 'NULL-NULL' to ''; creating the index for the first time after inserting the rows changes the index cited from <table>.<fulltext-index-name> to <table>.PRIMARY)

How to repeat:
See attached script; error does not occur every time and may be impacted by the timestamp used in the UUIDs since it usually fails reliably but sometimes starts to succeed many attempts in a row. Increasing the number of rows increases the chance of an error as does increasing the number of columns included in the index.
[29 Nov 2022 21:04] E M
Reproduction script

Attachment: test.sql (application/sql, text), 195.75 KiB.

[29 Nov 2022 21:05] E M
I also saw this reported here: https://stackoverflow.com/questions/73348896/add-multi-column-fulltext-index-fails-with-10...
[30 Nov 2022 4:42] MySQL Verification Team

Thank you for the report and feedback.
Verified as described.

[20 Dec 2022 14:18] Craig Crawford
Reproduction (~4m rows, python script)

Attachment: mysql-test.py (text/x-python), 4.76 KiB.

[20 Dec 2022 14:20] Craig Crawford
Have the same issue, was able to reproduce it using the above attached python (creates about ~4m rows in 40 sql files + 2 other sql files (create database, alter table), and runs the scripts...

Seems to fail frequently...

Running 99_altertable.sql in mysql
mysql: [Warning] Using a password on the command line interface can be insecure.
ERROR 1062 (23000) at line 4: Duplicate entry 'NULL-NULL-NULL' for key 'customers.customerFullText'
[21 Dec 2022 10:08] Craig Crawford
I forgot to add, the above is reproducible on MySQL 8.0.30.
[17 Jan 9:56] Calara Cristian
We ran into this issue as well. Not sure if anyone knows any workaround for this?