Exceptions: ER_BAD_FIELD_ERROR - wrong exception

ER_BAD_FIELD_ERROR (1054) was not handled and therefore
returned as OperationalError instead of ProgrammingError.
This commit is contained in:
Georg Richter
2025-01-30 13:55:34 +01:00
parent 7cfc325feb
commit 9508904911

View File

@ -82,6 +82,7 @@ static PyObject *get_exception_type(int error_number)
case ER_WRONG_DB_NAME:
case ER_WRONG_TABLE_NAME:
case ER_BAD_DB_ERROR:
case ER_BAD_FIELD_ERROR:
return Mariadb_ProgrammingError;
/* IntegrityError: Exception raised when the relational integrity of the database is affected,