Last modified: 2014-04-29 02:37:31 UTC
Our installer code only allows "-" in mysql db names. However the help message says its allowed for postgress. Should double check it works in postgress ( http://stackoverflow.com/questions/10216784/what-is-a-valid-postgresql-database-name suggests it does if it is quoted), and should either change the regex or change the help message. See also bug 25969
The hard part of this bug is that someone should actually test that using a db name with a "-" in it actually works with mediawiki.
After changing the regex, I installed against git HEAD with a PostgreSQL database named "my-wiki", and created and edited pages and uploaded files with no problem. Same with "my_wiki-". I also tried "-my_wiki", but that failed to upload files to it. But I also tried "-my_wiki" against mysql in 1.22.6, and that too failed. I did not test any extensions. I assumed that all connections where directed through a single codepath, and so if it worked anywhere it would work everywhere. But the failure to upload files to databases with leading hyphens contradicts that. Are there specific extensions I should test? So my conclusion is that database names with hyphens in them (no matter how unwise they may be) are supported by PostgreSQL just as much as by MySQL.