MySQLdb.constants.ER
index
MySQLdb/constants/ER.py

MySQL ER Constants
 
These constants are error codes for the bulk of the error conditions
that may occur.

 
Data
        ABORTING_CONNECTION = 1152
ACCESS_DENIED_ERROR = 1045
ALTER_INFO = 1088
AUTO_CONVERT = 1246
BAD_DB_ERROR = 1049
BAD_FIELD_ERROR = 1054
BAD_FT_COLUMN = 1283
BAD_HOST_ERROR = 1042
BAD_NULL_ERROR = 1048
BAD_SLAVE = 1200
BAD_SLAVE_UNTIL_COND = 1277
BAD_TABLE_ERROR = 1051
BINLOG_CREATE_ROUTINE_NEED_SUPER = 1419
BINLOG_PURGE_FATAL_ERR = 1377
BINLOG_PURGE_PROHIBITED = 1375
BINLOG_UNSAFE_ROUTINE = 1418
BLOBS_AND_NO_TERMINATED = 1084
BLOB_CANT_HAVE_DEFAULT = 1101
BLOB_KEY_WITHOUT_LENGTH = 1170
BLOB_USED_AS_KEY = 1073
CANNOT_ADD_FOREIGN = 1215
CANNOT_USER = 1396
CANT_AGGREGATE_2COLLATIONS = 1267
CANT_AGGREGATE_3COLLATIONS = 1270
CANT_AGGREGATE_NCOLLATIONS = 1271
CANT_CREATE_DB = 1006
CANT_CREATE_FEDERATED_TABLE = 1434
CANT_CREATE_FILE = 1004
CANT_CREATE_GEOMETRY_OBJECT = 1416
CANT_CREATE_TABLE = 1005
CANT_CREATE_THREAD = 1135
CANT_CREATE_USER_WITH_GRANT = 1410
CANT_DELETE_FILE = 1011
CANT_DO_THIS_DURING_AN_TRANSACTION = 1179
CANT_DROP_FIELD_OR_KEY = 1091
CANT_FIND_DL_ENTRY = 1127
CANT_FIND_SYSTEM_REC = 1012
CANT_FIND_UDF = 1122
CANT_GET_STAT = 1013
CANT_GET_WD = 1014
CANT_INITIALIZE_UDF = 1123
CANT_LOCK = 1015
CANT_OPEN_FILE = 1016
CANT_OPEN_LIBRARY = 1126
CANT_READ_DIR = 1018
CANT_REMOVE_ALL_FIELDS = 1090
CANT_REOPEN_TABLE = 1137
CANT_SET_WD = 1019
CANT_UPDATE_USED_TABLE_IN_SF_OR_TRG = 1442
CANT_UPDATE_WITH_READLOCK = 1223
CANT_USE_OPTION_HERE = 1234
CHECKREAD = 1020
CHECK_NOT_IMPLEMENTED = 1178
CHECK_NO_SUCH_TABLE = 1177
COLLATION_CHARSET_MISMATCH = 1253
COLUMNACCESS_DENIED_ERROR = 1143
COMMIT_NOT_ALLOWED_IN_SF_OR_TRG = 1422
CONFLICTING_DECLARATIONS = 1302
CONNECT_TO_FOREIGN_DATA_SOURCE = 1429
CONNECT_TO_MASTER = 1218
CON_COUNT_ERROR = 1040
CORRUPT_HELP_DB = 1244
CRASHED_ON_REPAIR = 1195
CRASHED_ON_USAGE = 1194
CREATE_DB_WITH_READ_LOCK = 1209
CUT_VALUE_GROUP_CONCAT = 1260
CYCLIC_REFERENCE = 1245
DATA_TOO_LONG = 1406
DATETIME_FUNCTION_OVERFLOW = 1441
DBACCESS_DENIED_ERROR = 1044
DB_CREATE_EXISTS = 1007
DB_DROP_DELETE = 1009
DB_DROP_EXISTS = 1008
DB_DROP_RMDIR = 1010
DELAYED_CANT_CHANGE_LOCK = 1150
DELAYED_INSERT_TABLE_LOCKED = 1165
DERIVED_MUST_HAVE_ALIAS = 1248
DIFF_GROUPS_PROC = 1384
DISK_FULL = 1021
DIVISION_BY_ZERO = 1365
DROP_DB_WITH_READ_LOCK = 1208
DROP_USER = 1268
DUMP_NOT_IMPLEMENTED = 1185
DUPLICATED_VALUE_IN_TYPE = 1291
DUP_ARGUMENT = 1225
DUP_ENTRY = 1062
DUP_FIELDNAME = 1060
DUP_KEY = 1022
DUP_KEYNAME = 1061
DUP_UNIQUE = 1169
EMPTY_QUERY = 1065
ERROR_DURING_CHECKPOINT = 1183
ERROR_DURING_COMMIT = 1180
ERROR_DURING_FLUSH_LOGS = 1182
ERROR_DURING_ROLLBACK = 1181
ERROR_LAST = 1457
ERROR_ON_CLOSE = 1023
ERROR_ON_READ = 1024
ERROR_ON_RENAME = 1025
ERROR_ON_WRITE = 1026
ERROR_WHEN_EXECUTING_COMMAND = 1220
EXEC_STMT_WITH_OPEN_CURSOR = 1420
FAILED_ROUTINE_BREAK_BINLOG = 1417
FEATURE_DISABLED = 1289
FIELD_SPECIFIED_TWICE = 1110
FILE_EXISTS_ERROR = 1086
FILE_NOT_FOUND = 1017
FILE_USED = 1027
FILSORT_ABORT = 1028
FLUSH_MASTER_BINLOG_CLOSED = 1186
FORBID_SCHEMA_CHANGE = 1450
FORCING_CLOSE = 1080
FOREIGN_DATA_SOURCE_DOESNT_EXIST = 1431
FOREIGN_DATA_STRING_INVALID = 1433
FOREIGN_DATA_STRING_INVALID_CANT_CREATE = 1432
FORM_NOT_FOUND = 1029
FPARSER_BAD_HEADER = 1341
FPARSER_EOF_IN_COMMENT = 1342
FPARSER_EOF_IN_UNKNOWN_PARAMETER = 1344
FPARSER_ERROR_IN_PARAMETER = 1343
FPARSER_TOO_BIG_FILE = 1340
FRM_UNKNOWN_TYPE = 1346
FSEEK_FAIL = 1376
FT_MATCHING_KEY_NOT_FOUND = 1191
FUNCTION_NOT_DEFINED = 1128
GET_ERRMSG = 1296
GET_ERRNO = 1030
GET_TEMPORARY_ERRMSG = 1297
GLOBAL_VARIABLE = 1229
GOT_SIGNAL = 1078
GRANT_WRONG_HOST_OR_USER = 1145
HANDSHAKE_ERROR = 1043
HASHCHK = 1000
HOST_IS_BLOCKED = 1129
HOST_NOT_PRIVILEGED = 1130
ILLEGAL_GRANT_FOR_TABLE = 1144
ILLEGAL_HA = 1031
ILLEGAL_REFERENCE = 1247
ILLEGAL_VALUE_FOR_TYPE = 1367
INCORRECT_GLOBAL_LOCAL_VAR = 1238
INDEX_REBUILD = 1187
INSERT_INFO = 1092
INSERT_TABLE_USED = 1093
INVALID_CHARACTER_STRING = 1300
INVALID_DEFAULT = 1067
INVALID_GROUP_FUNC_USE = 1111
INVALID_ON_UPDATE = 1294
INVALID_USE_OF_NULL = 1138
IO_ERR_LOG_INDEX_READ = 1374
IPSOCK_ERROR = 1081
KEY_COLUMN_DOES_NOT_EXITS = 1072
KEY_DOES_NOT_EXITS = 1176
KEY_NOT_FOUND = 1032
KEY_PART_0 = 1391
KEY_REF_DO_NOT_MATCH_TABLE_REF = 1240
KILL_DENIED_ERROR = 1095
LOAD_FROM_FIXED_SIZE_ROWS_TO_VAR = 1409
LOAD_INFO = 1087
LOCAL_VARIABLE = 1228
LOCK_DEADLOCK = 1213
LOCK_OR_ACTIVE_TRANSACTION = 1192
LOCK_TABLE_FULL = 1206
LOCK_WAIT_TIMEOUT = 1205
LOGGING_PROHIBIT_CHANGING_OF = 1387
LOG_IN_USE = 1378
LOG_PURGE_UNKNOWN_ERR = 1379
MALFORMED_DEFINER = 1446
MASTER = 1188
MASTER_FATAL_ERROR_READING_BINLOG = 1236
MASTER_INFO = 1201
MASTER_NET_READ = 1189
MASTER_NET_WRITE = 1190
MISSING_SKIP_SLAVE = 1278
MIXING_NOT_ALLOWED = 1224
MIX_OF_GROUP_FUNC_AND_FIELDS = 1140
MULTIPLE_PRI_KEY = 1068
M_BIGGER_THAN_D = 1427
NET_ERROR_ON_WRITE = 1160
NET_FCNTL_ERROR = 1155
NET_PACKETS_OUT_OF_ORDER = 1156
NET_PACKET_TOO_LARGE = 1153
NET_READ_ERROR = 1158
NET_READ_ERROR_FROM_PIPE = 1154
NET_READ_INTERRUPTED = 1159
NET_UNCOMPRESS_ERROR = 1157
NET_WRITE_INTERRUPTED = 1161
NEW_ABORTING_CONNECTION = 1184
NISAMCHK = 1001
NO = 1002
NONEXISTING_GRANT = 1141
NONEXISTING_PROC_GRANT = 1403
NONEXISTING_TABLE_GRANT = 1147
NONUNIQ_TABLE = 1066
NONUPDATEABLE_COLUMN = 1348
NON_UNIQ_ERROR = 1052
NON_UPDATABLE_TABLE = 1288
NORMAL_SHUTDOWN = 1077
NOT_ALLOWED_COMMAND = 1148
NOT_FORM_FILE = 1033
NOT_KEYFILE = 1034
NOT_SUPPORTED_AUTH_MODE = 1251
NOT_SUPPORTED_YET = 1235
NO_BINARY_LOGGING = 1381
NO_DB_ERROR = 1046
NO_DEFAULT = 1230
NO_DEFAULT_FOR_FIELD = 1364
NO_DEFAULT_FOR_VIEW_FIELD = 1423
NO_FILE_MAPPING = 1388
NO_GROUP_FOR_PROC = 1385
NO_PERMISSION_TO_CREATE_USER = 1211
NO_RAID_COMPILED = 1174
NO_REFERENCED_ROW = 1216
NO_REFERENCED_ROW_2 = 1452
NO_SUCH_INDEX = 1082
NO_SUCH_TABLE = 1146
NO_SUCH_THREAD = 1094
NO_SUCH_USER = 1449
NO_TABLES_USED = 1096
NO_UNIQUE_LOGFILE = 1098
NULL_COLUMN_IN_INDEX = 1121
OLD_FILE_FORMAT = 1455
OLD_KEYFILE = 1035
OPEN_AS_READONLY = 1036
OPERAND_COLUMNS = 1241
OPTION_PREVENTS_STATEMENT = 1290
ORDER_WITH_PROC = 1386
OUTOFMEMORY = 1037
OUT_OF_RESOURCES = 1041
OUT_OF_SORTMEMORY = 1038
PARSE_ERROR = 1064
PASSWD_LENGTH = 1372
PASSWORD_ANONYMOUS_USER = 1131
PASSWORD_NOT_ALLOWED = 1132
PASSWORD_NO_MATCH = 1133
PRIMARY_CANT_HAVE_NULL = 1171
PROCACCESS_DENIED_ERROR = 1370
PROC_AUTO_GRANT_FAIL = 1404
PROC_AUTO_REVOKE_FAIL = 1405
PS_MANY_PARAM = 1390
PS_NO_RECURSION = 1444
QUERY_INTERRUPTED = 1317
QUERY_ON_FOREIGN_DATA_SOURCE = 1430
QUERY_ON_MASTER = 1219
READY = 1076
READ_ONLY_TRANSACTION = 1207
RECORD_FILE_FULL = 1114
REGEXP_ERROR = 1139
RELAY_LOG_FAIL = 1371
RELAY_LOG_INIT = 1380
REQUIRES_PRIMARY_KEY = 1173
RESERVED_SYNTAX = 1382
REVOKE_GRANTS = 1269
ROW_IS_REFERENCED = 1217
ROW_IS_REFERENCED_2 = 1451
SELECT_REDUCED = 1249
SERVER_IS_IN_SECURE_AUTH_MODE = 1275
SERVER_SHUTDOWN = 1053
SET_CONSTANTS_ONLY = 1204
SHUTDOWN_COMPLETE = 1079
SLAVE_IGNORED_SSL_PARAMS = 1274
SLAVE_IGNORED_TABLE = 1237
SLAVE_MUST_STOP = 1198
SLAVE_NOT_RUNNING = 1199
SLAVE_THREAD = 1202
SLAVE_WAS_NOT_RUNNING = 1255
SLAVE_WAS_RUNNING = 1254
SPATIAL_CANT_HAVE_NULL = 1252
SPECIFIC_ACCESS_DENIED_ERROR = 1227
SP_ALREADY_EXISTS = 1304
SP_BADRETURN = 1313
SP_BADSELECT = 1312
SP_BADSTATEMENT = 1314
SP_BAD_CURSOR_QUERY = 1322
SP_BAD_CURSOR_SELECT = 1323
SP_BAD_SQLSTATE = 1407
SP_BAD_VAR_SHADOW = 1453
SP_CANT_ALTER = 1334
SP_CANT_SET_AUTOCOMMIT = 1445
SP_CASE_NOT_FOUND = 1339
SP_COND_MISMATCH = 1319
SP_CURSOR_AFTER_HANDLER = 1338
SP_CURSOR_ALREADY_OPEN = 1325
SP_CURSOR_MISMATCH = 1324
SP_CURSOR_NOT_OPEN = 1326
SP_DOES_NOT_EXIST = 1305
SP_DROP_FAILED = 1306
SP_DUP_COND = 1332
SP_DUP_CURS = 1333
SP_DUP_HANDLER = 1413
SP_DUP_PARAM = 1330
SP_DUP_VAR = 1331
SP_FETCH_NO_DATA = 1329
SP_GOTO_IN_HNDLR = 1358
SP_LABEL_MISMATCH = 1310
SP_LABEL_REDEFINE = 1309
SP_LILABEL_MISMATCH = 1308
SP_NORETURN = 1320
SP_NORETURNEND = 1321
SP_NOT_VAR_ARG = 1414
SP_NO_DROP_SP = 1357
SP_NO_RECURSION = 1424
SP_NO_RECURSIVE_CREATE = 1303
SP_NO_RETSET = 1415
SP_PROC_TABLE_CORRUPT = 1457
SP_RECURSION_LIMIT = 1456
SP_STORE_FAILED = 1307
SP_SUBSELECT_NYI = 1335
SP_UNDECLARED_VAR = 1327
SP_UNINIT_VAR = 1311
SP_VARCOND_AFTER_CURSHNDLR = 1337
SP_WRONG_NO_OF_ARGS = 1318
SP_WRONG_NO_OF_FETCH_ARGS = 1328
STACK_OVERRUN = 1119
STACK_OVERRUN_NEED_MORE = 1436
STARTUP = 1408
STMT_HAS_NO_OPEN_CURSOR = 1421
STMT_NOT_ALLOWED_IN_SF_OR_TRG = 1336
SUBQUERY_NO_1_ROW = 1242
SYNTAX_ERROR = 1149
TABLEACCESS_DENIED_ERROR = 1142
TABLENAME_NOT_ALLOWED_HERE = 1250
TABLE_CANT_HANDLE_AUTO_INCREMENT = 1164
TABLE_CANT_HANDLE_BLOB = 1163
TABLE_CANT_HANDLE_FT = 1214
TABLE_DEF_CHANGED = 1412
TABLE_EXISTS_ERROR = 1050
TABLE_MUST_HAVE_COLUMNS = 1113
TABLE_NOT_LOCKED = 1100
TABLE_NOT_LOCKED_FOR_WRITE = 1099
TEXTFILE_NOT_READABLE = 1085
TOO_BIG_DISPLAYWIDTH = 1439
TOO_BIG_FIELDLENGTH = 1074
TOO_BIG_FOR_UNCOMPRESS = 1256
TOO_BIG_PRECISION = 1426
TOO_BIG_ROWSIZE = 1118
TOO_BIG_SCALE = 1425
TOO_BIG_SELECT = 1104
TOO_BIG_SET = 1097
TOO_LONG_BODY = 1437
TOO_LONG_IDENT = 1059
TOO_LONG_KEY = 1071
TOO_LONG_STRING = 1162
TOO_MANY_DELAYED_THREADS = 1151
TOO_MANY_FIELDS = 1117
TOO_MANY_KEYS = 1069
TOO_MANY_KEY_PARTS = 1070
TOO_MANY_ROWS = 1172
TOO_MANY_TABLES = 1116
TOO_MANY_USER_CONNECTIONS = 1203
TOO_MUCH_AUTO_TIMESTAMP_COLS = 1293
TRANS_CACHE_FULL = 1197
TRG_ALREADY_EXISTS = 1359
TRG_CANT_CHANGE_ROW = 1362
TRG_DOES_NOT_EXIST = 1360
TRG_IN_WRONG_SCHEMA = 1435
TRG_NO_DEFINER = 1454
TRG_NO_SUCH_ROW_IN_TRG = 1363
TRG_ON_VIEW_OR_TEMP_TABLE = 1361
TRUNCATED_WRONG_VALUE = 1292
TRUNCATED_WRONG_VALUE_FOR_FIELD = 1366
UDF_EXISTS = 1125
UDF_NO_PATHS = 1124
UNEXPECTED_EOF = 1039
UNION_TABLES_IN_DIFFERENT_DIR = 1212
UNKNOWN_CHARACTER_SET = 1115
UNKNOWN_COLLATION = 1273
UNKNOWN_COM_ERROR = 1047
UNKNOWN_ERROR = 1105
UNKNOWN_KEY_CACHE = 1284
UNKNOWN_PROCEDURE = 1106
UNKNOWN_STMT_HANDLER = 1243
UNKNOWN_STORAGE_ENGINE = 1286
UNKNOWN_SYSTEM_VARIABLE = 1193
UNKNOWN_TABLE = 1109
UNKNOWN_TARGET_BINLOG = 1373
UNKNOWN_TIME_ZONE = 1298
UNSUPPORTED_EXTENSION = 1112
UNSUPPORTED_PS = 1295
UNTIL_COND_IGNORED = 1279
UPDATE_INFO = 1134
UPDATE_LOG_DEPRECATED_IGNORED = 1315
UPDATE_LOG_DEPRECATED_TRANSLATED = 1316
UPDATE_WITHOUT_KEY_IN_SAFE_MODE = 1175
USER_LIMIT_REACHED = 1226
VARIABLE_IS_NOT_STRUCT = 1272
VAR_CANT_BE_READ = 1233
VIEW_CHECKSUM = 1392
VIEW_CHECK_FAILED = 1369
VIEW_DELETE_MERGE_VIEW = 1395
VIEW_FRM_NO_USER = 1447
VIEW_INVALID = 1356
VIEW_MULTIUPDATE = 1393
VIEW_NONUPD_CHECK = 1368
VIEW_NO_EXPLAIN = 1345
VIEW_NO_INSERT_FIELD_LIST = 1394
VIEW_OTHER_USER = 1448
VIEW_PREVENT_UPDATE = 1443
VIEW_SELECT_CLAUSE = 1350
VIEW_SELECT_DERIVED = 1349
VIEW_SELECT_TMPTABLE = 1352
VIEW_SELECT_VARIABLE = 1351
VIEW_WRONG_LIST = 1353
WARNING_NOT_COMPLETE_ROLLBACK = 1196
WARN_ALLOWED_PACKET_OVERFLOWED = 1301
WARN_CANT_DROP_DEFAULT_KEYCACHE = 1438
WARN_DATA_OUT_OF_RANGE = 1264
WARN_DATA_TRUNCATED = 1265
WARN_DEPRECATED_SYNTAX = 1287
WARN_FIELD_RESOLVED = 1276
WARN_HOSTNAME_WONT_WORK = 1285
WARN_INVALID_TIMESTAMP = 1299
WARN_NULL_TO_NOTNULL = 1263
WARN_QC_RESIZE = 1282
WARN_TOO_FEW_RECORDS = 1261
WARN_TOO_MANY_RECORDS = 1262
WARN_USING_OTHER_HANDLER = 1266
WARN_VIEW_MERGE = 1354
WARN_VIEW_WITHOUT_KEY = 1355
WRONG_ARGUMENTS = 1210
WRONG_AUTO_KEY = 1075
WRONG_COLUMN_NAME = 1166
WRONG_DB_NAME = 1102
WRONG_FIELD_SPEC = 1063
WRONG_FIELD_TERMINATORS = 1083
WRONG_FIELD_WITH_GROUP = 1055
WRONG_FK_DEF = 1239
WRONG_GROUP_FIELD = 1056
WRONG_KEY_COLUMN = 1167
WRONG_LOCK_OF_SYSTEM_TABLE = 1428
WRONG_MAGIC = 1389
WRONG_MRG_TABLE = 1168
WRONG_NAME_FOR_CATALOG = 1281
WRONG_NAME_FOR_INDEX = 1280
WRONG_NUMBER_OF_COLUMNS_IN_SELECT = 1222
WRONG_OBJECT = 1347
WRONG_OUTER_JOIN = 1120
WRONG_PARAMCOUNT_TO_PROCEDURE = 1107
WRONG_PARAMETERS_TO_PROCEDURE = 1108
WRONG_SUB_KEY = 1089
WRONG_SUM_SELECT = 1057
WRONG_TABLE_NAME = 1103
WRONG_TYPE_FOR_VAR = 1232
WRONG_USAGE = 1221
WRONG_VALUE_COUNT = 1058
WRONG_VALUE_COUNT_ON_ROW = 1136
WRONG_VALUE_FOR_TYPE = 1411
WRONG_VALUE_FOR_VAR = 1231
WSAS_FAILED = 1383
XAER_DUPID = 1440
XAER_INVAL = 1398
XAER_NOTA = 1397
XAER_OUTSIDE = 1400
XAER_RMERR = 1401
XAER_RMFAIL = 1399
XA_RBROLLBACK = 1402
YES = 1003
ZLIB_Z_BUF_ERROR = 1258
ZLIB_Z_DATA_ERROR = 1259
ZLIB_Z_MEM_ERROR = 1257