Boston Linux & Unix (BLU) Home | Calendar | Mail Lists | List Archives | Desktop SIG | Hardware Hacking SIG
Wiki | Flickr | PicasaWeb | Video | Maps & Directions | Installfests | Keysignings
Linux Cafe | Meeting Notes | Blog | Linux Links | Bling | About BLU

BLU Discuss list archive


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Discuss] mysql brain teaser...



On 02/26/2012 09:17 AM, Stephen Adler wrote:
> Check this out for a mysql brain tease.... I'm working on a new database
> project and on my development system I run a separate mysql database
> server to develop against. So today I found the following in my list of
> databases in my development mysql database server.
> 
> 
> mysql> show databases;
> +--------------------+
> | Database           |
> +--------------------+
> | information_schema |
> | #mysql50#.emacs.d  |
> | clinicaldb         |
> | mysql              |
> | performance_schema |
> | test               |
> +--------------------+
> 6 rows in set (0.00 sec)
> 
> So what is this #mysql50#.emacs.d database? I did a quick search and
> found that #mysql50# prefix means that a database was upgrade which my
> have happened as I've upgraded through various releases of Fedora. But
> the .emacs.d is the weird part. The database contains `.` characters
> which are supposidly not allowed according to the following link
> 
> http://dev.mysql.com/doc/refman/5.0/en/identifiers.html
> 
> does anyone have a suggestion as to how I can check to see what tables
> are in this database and/or how to drop the database?

The brute force answer to both questions is to mysqldump all tables (so
you don't need to specify that table name anywhere), and look at the
dump to see what's in that database.

To remove it, simply remove that table from the dump with your favorite
editor (use emacs for extra irony), drop all databases, and reload the
dump which no longer contains that database.




BLU is a member of BostonUserGroups
BLU is a member of BostonUserGroups
We also thank MIT for the use of their facilities.

Valid HTML 4.01! Valid CSS!



Boston Linux & Unix / webmaster@blu.org