Home > MySQL Error Codes Out Of Context

MySQL Error Codes Out Of Context

In the wrong context, almost anything can be funny, and MySQL’s error codes are no exception. A few weeks ago, things got a little loopy as we discovered some definitions that could be taken more than one way.

How It Began

It started with ER_M_BIGGER_THAN_D, which doesn’t sound like an error at all. Anyone who knows alphabetical order knows that M is bigger than D! Of course, the error is really about an attempt to define a decimal or float column wrongly. Next was ER_TOO_BIG_SCALE, about which I tweeted “MongoDB doesn’t have this error, as far as I know, but MySQL does.” Which reminded us of Big Data, of course.

Doge Error Codes

We have an inexplicable fixation for the Doge meme. Our chatbot even has a /doge me command. If you’re not familiar with the meme, it’s basically pictures and variations of pictures of a dog, with Comic Sans font representing his internal dialogue expressing his feelings of amazement at his superiority. His grammar is oddly stilted, with awkward use of superlatives like “such,” “many,” and “very.” Of course, there are some Doge error codes, which we sprinkled in our chat channel with Doge emoticons. Doge_error_code We decided, however, that ER_CANNOT_USER is “the dogest of them all.” User isn’t a verb, but Doge likes to verb words. It weirds language.

Other Fun Errors

Here’s a sprinkling of some other fun error definitions:
  • ER_NORMAL_SHUTDOWN - wait, is that an error?
  • ER_ALTER_INFO - its doppelganger is ER_ALTER_EGO
  • ER_TABLE_CANT_HANDLE_BLOB - unless the table is named STEVE_MCQUEEN
  • ER_KEY_DOES_NOT_EXITS - [sic]
Take a look through the definitions and see if you can find any more of your own!

Ready For Connections

Finally, there’s ER_STARTUP. It’s not what it seems, though. This is the familiar ready-for-business message in the server’s log:
Error: 1408 SQLSTATE: HY000 (ER_STARTUP) Message: %s: ready for connections. Version: '%s' socket: '%s' port: %d %s 
At SolarWinds we’re ready for business, too. If you’d like to monitor MySQL queries and performance the easy way with SolarWinds Database Performance Monitor (DPM), sign up for a free trial today.

But Seriously, Folks

This all came about for two reasons. First, we added an opensource package of error code definitions for Go. No more comparisons to magic numbers or strings when you get an error from the server. Second, as you may know, SolarWinds DPM captures production query traffic from the network, and reveals hidden details such as queries that return warnings or errors to clients. We’re in the process of making the user interface expose those errors and messages more nicely. Of course, we need a list of those, which you can find in the errmsg.sys file in the server distribution. (Trivia fact: aside from this file, the mysqld binary is self-contained and can be run without other dependencies.) Now, go forth and err no more!
Baron Schwartz
Baron is a performance and scalability expert who participates in various database, open-source, and distributed systems communities. He has helped build and scale many large,…
Read more

Tweets

SolarWinds's Twitter avatar
SolarWinds
@solarwinds

The future of IT lies in the cloud, but is this future still “cloud native”? Learn why this question is increasingl… t.co/6aOxFFWeD7

SolarWinds's Twitter avatar
SolarWinds
@solarwinds

Considering a #multicloud strategy? Here’s what to consider before adopting. t.co/0lzaykD7SE via @vmblog

SolarWinds's Twitter avatar
SolarWinds
@solarwinds

@SteHollyoak We apologize for the inconvenience. Please DM us your contact information, and we'll escalate to the team. Thank you.