Bug #3091 | Field named 'time' can not be updated with '...time=time+1' | ||
---|---|---|---|
Submitted: | 7 Mar 2004 6:47 | Modified: | 7 Mar 2004 11:48 |
Reporter: | Elifant'ev Oleg | Email Updates: | |
Status: | Won't fix | Impact on me: | |
Category: | MySQL Server | Severity: | S2 (Serious) |
Version: | 4.0.18 | OS: | FreeBSD (FreeBSD 5.0-5.2) |
Assigned to: | Sergei Golubchik | CPU Architecture: | Any |
[7 Mar 2004 6:47]
Elifant'ev Oleg
[7 Mar 2004 11:48]
Sergei Golubchik
The bug is in how lexer splits an incoming stream into tokens. "time" is a keyword (though not reserved) lexer erroneously parser the statement as keyword("update") identifier("tsttbl") keyword("set") keyword("time") operator("=") keyword("time") number("+1") while the correct splitting is ... keyword("time") operator("+") number("1") It is fixed in 4.1 already, but unfortunately the fix is too big and too intrusive to go into the stable version (such as 4.0). As a workaround you may put a space between "+" and "1".