For example, when I go to the mysql command line and do:
mysql> create database `#mysql#testdb`;
and try:
mysql> show databases;
I only get a db named "testdb" and NOT "#mysql#testdb".
Any idea what's wrong here?
You use special characters like # (sql comments). If you can avoid it, use the underscore '_' instead of #. Otherwise, look at this page, it should help you to use the special characters.