Closed arvidfm closed 1 month ago
Our standard response to "deprecated in the latest MySQL but still works" is to say only if you really need it. Can you work around this one? We would hate to implement it and then have to tear it out. We don't track deprecated MySQL sytax very well.
A year ago I would have said it was a blocker, since it's the only syntax that's compatible with both MySQL 5.7 and 8.x, but with 5.7 being EOL and us not supporting it anymore, we need to be porting our queries over to use window functions anyway. So as far as our use case goes at least, this is not a concern, and I only created this issue for completeness' sake.
OK. I'll close as won't fix. Thanks for all the issues and great repros.
Though the syntax is deprecated, in MySQL you can currently use
:=
in e.g.UPDATE
(and I believeINSERT
) statements to generate a sequence. For example, if you have a table when you want to set atbl.ind
column to be a unique index, ordered by when the entry was created, you could do something like this:This is currently a syntax error in Dolt.
Note that this syntax has been deprecated in favour of using window functions instead, and will be removed in a future version of MySQL, so implementing this would only be of interest for the sake of compatibility with existing queries.
Standalone MWE: