Bug #67588 The error message for syntax errors is ridiculously difficult to read
Description:
I know this error message is a beautiful piece of history:
"You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ..."
Then print it and expose it in a museum, but please remove it from current versions of the software that are meant to be (and actually are) used.
As a developer, this is one of the worst ways of reporting an error I've ever seen in a modern computer language.
* To start with, it's ridiculously long. "You have an error in your SQL syntax" can be reduced to "SQL Syntax error;"
* The part "Check the manual bla bla..... syntax to use" is completely useless and can be removed safely without loosing a bit of information.
* For god's sake at the very least replace "NEAR" with "JUST BEFORE"
* Explain what's wrong with the syntax. "Unexpected token '...'", or whatever.
One stares at the error message and half of it is useless junk, the other half is a part of the query that most of the times does NOT contain the error.
How to repeat:
send a query with a syntax error
Suggested fix:
I know this error message is a beautiful piece of history:
"You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ..."
Then print it and expose it in a museum, but please remove it from current versions of the software that are meant to be (and actually are) used.
As a developer, this is one of the worst ways of reporting an error I've ever seen in a modern computer language.
* To start with, it's ridiculously long. "You have an error in your SQL syntax" can be reduced to "SQL Syntax error;"
* The part "Check the manual bla bla..... syntax to use" is completely useless and can be removed safely without loosing a bit of information.
* For god's sake at the very least replace "NEAR" with "JUST BEFORE"
* Explain what's wrong with the syntax. "Unexpected token '...'", or whatever.
One stares at the error message and half of it is useless junk, the other half is a part of the query that most of the times does NOT contain the error.
Portions of this website are copyright © 2001, 2002 The PHP Group
Page generated in 0.039 sec. using MySQL 8.4.7-u6-cloud
Timestamp references displayed by the system are UTC.
Content reproduced on this site is the property of the
respective copyright holders.
It is not reviewed in advance
by Oracle and does not necessarily represent the opinion of
Oracle or any other party.