You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I noticed that aerich handles enums strangely. Instead of creating them as ENUM field in the table, a VARCHAR(length of the longest field in the enum) is used and the intended values are stored as a commetar at the field.
However, this currently leads to problems for me, I have relatively many entries in an enum, which is why I get an error when I try to execute the migration.
pymysql.err.OperationalError: (1629, "Comment for field 'type' is too long (max = 1024)")
My workaround is to remove the comment field from the migration. However, this is a bit annoying in the long run, because aerich tries to add the comment every time I create a new migration.
Is there any plan to support enum fields in the database as well?
The text was updated successfully, but these errors were encountered:
l1f
changed the title
Problem with log enums
Problem with long enums
Nov 14, 2022
I noticed that aerich handles enums strangely. Instead of creating them as ENUM field in the table, a VARCHAR(length of the longest field in the enum) is used and the intended values are stored as a commetar at the field.
However, this currently leads to problems for me, I have relatively many entries in an enum, which is why I get an error when I try to execute the migration.
pymysql.err.OperationalError: (1629, "Comment for field 'type' is too long (max = 1024)")
My workaround is to remove the comment field from the migration. However, this is a bit annoying in the long run, because aerich tries to add the comment every time I create a new migration.
Is there any plan to support enum fields in the database as well?
The text was updated successfully, but these errors were encountered: