Can't create MySql databases with uppercase name

5 posts / 0 new
Last post
#1 Fri, 09/26/2008 - 03:54
webamine.fr

Can't create MySql databases with uppercase name

Hi,

My co-worker has a problem with Virtualmin : he can't create databases with UPPERCASE names ("edit databases" on a virtualmin hosts).

Only lower case databases are created. So he has to go Webmin instead to create such databases, but the problem is that then these databases are not linked correctly to the user / vhost and so he has to do some part of the job manually.

I don't really know what to do to help... do you have any idea where this strange behaviour could come from please ?

Thx.

Mon, 09/29/2008 - 14:51
jmarsden

deleted duplicate post.<br><br>Post edited by: jmarsden, at: 2008/09/29 15:39

Mon, 09/29/2008 - 14:57 (Reply to #2)
Joe
Joe's picture

There's some reason for that code...but I don't remember what it is. (And it may not be a useful reason in this particular case, or even in the general case. It could very well be an edge case issue that most people would never see. I dunno. What I'm saying is, "try it and see".)

--

Check out the forum guidelines!

Mon, 09/29/2008 - 15:38 (Reply to #3)
jmarsden

The comments for that function don't give any hint of a reason, either, saying only:

# If a database name starts with a number, convert it to a word to support
# PostgreSQL, which doesn't like numeric names. Also converts . and - to _,
# and handles reserved DB names.

It would be better coding practice to include some comment regarding the lowercasing of database names in there, I think.

Tue, 10/07/2008 - 04:31 (Reply to #4)
webamine.fr

Ok, so it's like some feature to adapt databases for compatibility ?
It was a little troublesome because we imported databases and parts of
databases from other servers, so we had to adapt either the code or
the databases names manually to fit.

Regards,
François.

Topic locked