Bug #90058 Note for dropping a non-existent table not shown
Submitted: 14 Mar 2018 9:55 Modified: 14 Mar 2018 10:14
Reporter: Daniël van Eeden (OCA) Email Updates:
Status: Duplicate Impact on me:
None 
Category:MySQL Server: DDL Severity:S3 (Non-critical)
Version:5.7.20 OS:Any
Assigned to: CPU Architecture:Any

[14 Mar 2018 9:55] Daniël van Eeden
Description:
The note for dropping a non-existent database is not available to SHOW WARNINGS if not using the \W client option. 

mysql> drop database if exists wegsdfsdgd;
Query OK, 0 rows affected, 1 warning (0.00 sec)

mysql> show warnings;
Empty set (0.00 sec)

mysql> \W
Show warnings enabled.
mysql> drop database if exists wegsdfsdgd;
Query OK, 0 rows affected, 1 warning (0.00 sec)

Note (Code 1008): Can't drop database 'wegsdfsdgd'; database doesn't exist
mysql> show warnings;
+-------+------+----------------------------------------------------------+
| Level | Code | Message                                                  |
+-------+------+----------------------------------------------------------+
| Note  | 1008 | Can't drop database 'wegsdfsdgd'; database doesn't exist |
+-------+------+----------------------------------------------------------+
1 row in set (0.00 sec)

mysql> select version();
+-----------+
| version() |
+-----------+
| 5.7.20    |
+-----------+
1 row in set (0.00 sec)

How to repeat:
See description.
[14 Mar 2018 10:14] MySQL Verification Team
Hello Daniël,

Thank you for the report.
This is duplicate of Bug #79684.

Thanks,
Umesh