Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

AutoMigrate will create many indexes of the same field #6304

Closed
lixh00 opened this issue May 9, 2023 · 3 comments
Closed

AutoMigrate will create many indexes of the same field #6304

lixh00 opened this issue May 9, 2023 · 3 comments
Assignees
Labels

Comments

@lixh00
Copy link

lixh00 commented May 9, 2023

GORM Playground Link

go-gorm/playground#1

Description

AutoMigrate会创建很多个同字段的索引,如下图所示
AutoMigrate will create many indexes of the same field, as shown in the figure below

image

@github-actions github-actions bot added the type:missing reproduction steps missing reproduction steps label May 9, 2023
@github-actions
Copy link

github-actions bot commented May 9, 2023

The issue has been automatically marked as stale as it missing playground pull request link, which is important to help others understand your issue effectively and make sure the issue hasn't been fixed on latest master, checkout https://github.com/go-gorm/playground for details. it will be closed in 30 days if no further activity occurs. if you are asking question, please use the Question template, most likely your question already answered https://github.com/go-gorm/gorm/issues or described in the document https://gorm.ioSearch Before Asking

@a631807682
Copy link
Member

duplicated of #6224

@lixh00
Copy link
Author

lixh00 commented May 30, 2023

duplicated of #6224

The maximum number of MySQL single-table indexes is 64. This BUG will keep creating until all quotas are used up and AutoMigrate can no longer be used.

MySQL单表索引数最大为64个,这个BUG会一直创建,直到用完所有额度导致无法再AutoMigrate。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants