| Bug #12591 | SHOW TABLES FROM dbname produces wrong error message | ||
|---|---|---|---|
| Submitted: | 15 Aug 2005 20:01 | Modified: | 24 Aug 2005 17:18 |
| Reporter: | Dean Ellis | Email Updates: | |
| Status: | Closed | Impact on me: | |
| Category: | MySQL Server | Severity: | S3 (Non-critical) |
| Version: | 4.0/4.1/5.0 | OS: | Linux (Linux/Windows) |
| Assigned to: | Andrey Hristov | CPU Architecture: | Any |
[15 Aug 2005 21:29]
MySQL Verification Team
Verified on BK source 4.0/4.1/5.0.
[17 Aug 2005 15:51]
Bugs System
A patch for this bug has been committed. After review, it may be pushed to the relevant source trees for release in the next version. You can access the patch from: http://lists.mysql.com/internals/28404
[24 Aug 2005 17:18]
Mike Hillyer
Documented in 5.0.12 changelog: <listitem><para><literal>SHOW TABLES FROM</literal> returned wrong error message if the schema specified did not exist. (Bug #12591)</para></listitem>

Description: SHOW TABLES FROM nonexistent_database; reports the filesystem error (ie: "ERROR 12 (HY000): Can't read dir of './nosuchdatabase/' (Errcode: 2)") instead of a "bad database" error. How to repeat: USE nosuchdatabase; SHOW TABLES FROM nosuchdatabase; Suggested fix: Report errno 1049 ("ERROR 1049 (42000): Unknown database 'nosuchdatabase'") instead. Filesystem error could perhaps go into the errlog.