debugsqlMinor
What is the HY number (HY000) in MySQL Error messages?
Viewed 0 times
numbertheerrorwhatmysqlmessageshy000
Problem
When I get an error some of them have an
ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2 "No such file or directory")
What is
HY code,ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2 "No such file or directory")
What is
HY000 in the above context. See this question for another example of HY000 in an error messageSolution
MySQL reports with ODBC error numbers which include a
A five-character SQLSTATE value ('42S02'). The values are taken from ANSI SQL and ODBC and are more standardized. Not all MySQL error numbers have corresponding SQLSTATE values. In these cases, 'HY000' (general error) is used.
You can find the
The
SQLSTATE. HY000 is a MySQL ODBC extension for there being no ODBC equivalent error number from the docs on Server Error Codes and MessagesA five-character SQLSTATE value ('42S02'). The values are taken from ANSI SQL and ODBC and are more standardized. Not all MySQL error numbers have corresponding SQLSTATE values. In these cases, 'HY000' (general error) is used.
You can find the
HY000 Error Codes in error_code.h, and the full list of authoritative ODBC error codes from the Microsoft ODBC AppendixThe
2 "No such file or directory" is operating system specific.Context
StackExchange Database Administrators Q#208615, answer score: 4
Revisions (0)
No revisions yet.