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
Easily worked around by just ordering the column properties as Dolt requires, though can be a little inconvenient with some connectors such as knex's schema builder which apparently always orders NOT NULL before COLLATE, thus requiring to break out into a raw sql statement to reorder them.
I apologize for the delay, I thought this would take 30 min but ended up taking almost 2 days. To put it short, allowing NOT NULL to come before COLLATE made the parser ambiguous, and finding the issue was not obvious at all (along with figuring out a fix). Turns out our handling of DEFAULT values was completely wrong, and we accounted for it in go-mysql-server, but that incorrect-ness was the root cause of the ambiguity in our parser.
The PR fixing this issue is linked in the sidebar. We'll do another release once the change makes its way into Dolt later today.
In MySQL, when modifying a column in an ALTER TABLE operation, you can specify the column as being NOT NULL as well as its collation in any order.
In Dolt, it reports a syntax error if NOT NULL is defined before COLLATE.
MySQL:
Dolt:
The text was updated successfully, but these errors were encountered: