-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
Changing ENUM value corrupts row using changed valued #920
Comments
@bolt-leandro this should be resolved by #963, which is currently on Can you test with |
@timvaillancourt I tested again with version 1.1.4 (sorry about late reply, missed notification) and still getting the same behaviour. Changing the ENUM values results in empty enum value both on 5.7.32-35 and 8.0.22-13 (attached similar results) |
@bolt-leandro thanks, I've started to create a localtest that reproduces this in #1177: Testing: enum-modified......ERROR enum-modified: checksum mismatch
---
2c2
< 2 8 Fail
---
> 2 8
diff /tmp/gh-ost-test.orig.content.csv /tmp/gh-ost-test.ghost.content.csv I'll take a stab at fixing this whenever I can find more time 👍 I just realized that one of the reasons this may not be reported already is changing existing enum columns could break a live-running application I'm curious how your app will handle that in this use case? In your example above, I'd expect writes that set |
We got the same error as well. |
2022-10-13 04:47:38 FATAL Error 1048: Column 'payment_type' cannot be null; query= |
The app needs to stop issuing writes that set Some insight on the problem. If doing a native ALTER, it will refuse to change the tbale if it needs to truncate existing
In MySQL, removing the
|
Hello!
Attempting to change ENUM values results in wrong data for the value changed. Test case is below. Feel free to ask for any more information you might need.
HERE WE RUN GH-OST (more verbose logs below)
--alter="MODIFY COLUMN Result enum('Pass','MostExcellent') NOT NULL" \
NOW WE CHECK RESULTS AFTER CUTOVER AND SEE SOMETHING IS WRONG WITH OUR ENUM
GH-OST COMMAND DETAILS (ALSO TRIED 1.1.0 AND GOT SAME RESULTS)
The text was updated successfully, but these errors were encountered: