MySQL :: MySQL 8.0 Reference Manual :: 15.7.7.17 SHOW ERRORS Statement (original) (raw)

15.7.7.17 SHOW ERRORS Statement

SHOW ERRORS [LIMIT [offset,] row_count]
SHOW COUNT(*) ERRORS

SHOW ERRORS is a diagnostic statement that is similar to SHOW WARNINGS, except that it displays information only for errors, rather than for errors, warnings, and notes.

The LIMIT clause has the same syntax as for the SELECT statement. SeeSection 15.2.13, “SELECT Statement”.

The SHOW COUNT(*) ERRORS statement displays the number of errors. You can also retrieve this number from theerror_count variable:

SHOW COUNT(*) ERRORS;
SELECT @@error_count;

SHOW ERRORS anderror_count apply only to errors, not warnings or notes. In other respects, they are similar to SHOW WARNINGS andwarning_count. In particular,SHOW ERRORS cannot display information for more thanmax_error_count messages, anderror_count can exceed the value of max_error_count if the number of errors exceedsmax_error_count.

For more information, see Section 15.7.7.42, “SHOW WARNINGS Statement”.