# Show Warnings And Errors

__*SHOW WARNINGS*__
__*SHOW ERRORS*__

+ **`SHOW WARNINGS`** and **`SHOW ERRORS`**  
```
tidb> CREATE TABLE test.bt2 (id BIGINT KEY AUTO_RANDOM);
Query OK, 0 rows affected, 1 warning (0.09 sec)

tidb> SHOW WARNINGS;
+-------+------+---------------------------------------------------------+
| Level | Code | Message                                                 |
+-------+------+---------------------------------------------------------+
| Note  | ~!@1105@!~ | Available implicit allocation times: 288230376151711743 |
+-------+------+---------------------------------------------------------+
tidb> SELECT invalid;
ERROR ~!@1054@!~ (42S22): Unknown column 'invalid' in 'field list'

tidb> SHOW ERRORS;
+-------+------+------------------------------------------+
| Level | Code | Message                                  |
+-------+------+------------------------------------------+
| Error | ~!@1054@!~ | Unknown column 'invalid' in 'field list' |
+-------+------+------------------------------------------+

tidb> SHOW WARNINGS;
+-------+------+------------------------------------------+
| Level | Code | Message                                  |
+-------+------+------------------------------------------+
| Error | ~!@1054@!~ | Unknown column 'invalid' in 'field list' |
+-------+------+------------------------------------------+
```

------------------------------------------------------------
TiDB is compatible with error codes in MySQL, and in most cases the error code return is the same as MySQL.

See the complete list of error codes on `https://docs.pingcap.com/tidb/stable/error-codes` . Also, some error codes represent internal errors. Normally, TiDB handles the error rather than return it to the user.

