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

Consider column lengths when comparing indices #3415

Merged
merged 1 commit into from
Dec 27, 2018

Conversation

morozov
Copy link
Member

@morozov morozov commented Dec 19, 2018

Q A
Type bug

When comparing indices, compare column lengths as well. Fixes #3414.

@morozov
Copy link
Member Author

morozov commented Dec 19, 2018

Not sure how this is supposed to work when the target platform doesn't support index lengths but they are specified in the metadata. Something should remove lengths from the target definitions in order to avoid the diff which is impossible to eliminate.

Copy link
Member

@Ocramius Ocramius left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

@morozov morozov merged commit df4071e into doctrine:master Dec 27, 2018
@morozov morozov deleted the issues/3414 branch December 27, 2018 20:37
morozov added a commit that referenced this pull request Dec 27, 2018
@leofeyer
Copy link
Contributor

Thank you @morozov. 👍

@rvanlaak
Copy link

We started seeing the following error after updating from 2.9.0 to 2.9.2

[PDOException (42000)]
SQLSTATE[42000]: Syntax error or access violation: 1071 Specified key was t
oo long; max key length is 767 bytes

The schema tool did try to drop and create the index, but was not able to make the change. We were able to solve it by manually removing the index length, after which the schema tool did not detect a change for the index anymore.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Aug 9, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants